diff options
Diffstat (limited to 'src/test/ui/resolve/issue-5099.rs')
-rw-r--r-- | src/test/ui/resolve/issue-5099.rs | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/test/ui/resolve/issue-5099.rs b/src/test/ui/resolve/issue-5099.rs new file mode 100644 index 000000000..b5abccb4b --- /dev/null +++ b/src/test/ui/resolve/issue-5099.rs @@ -0,0 +1,13 @@ +trait B <A> { + fn a() -> A { + this.a //~ ERROR cannot find value `this` in this scope + } + fn b(x: i32) { + this.b(x); //~ ERROR cannot find value `this` in this scope + } + fn c() { + let _ = || this.a; //~ ERROR cannot find value `this` in this scope + } +} + +fn main() {} |