diff options
Diffstat (limited to 'src/test/ui/parser/issues/issue-70549-resolve-after-recovered-self-ctor.rs')
-rw-r--r-- | src/test/ui/parser/issues/issue-70549-resolve-after-recovered-self-ctor.rs | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/src/test/ui/parser/issues/issue-70549-resolve-after-recovered-self-ctor.rs b/src/test/ui/parser/issues/issue-70549-resolve-after-recovered-self-ctor.rs new file mode 100644 index 000000000..aeccd0d9f --- /dev/null +++ b/src/test/ui/parser/issues/issue-70549-resolve-after-recovered-self-ctor.rs @@ -0,0 +1,18 @@ +struct S {} + +impl S { + fn foo(&mur Self) {} + //~^ ERROR expected identifier, found keyword `Self` + //~| ERROR expected one of `:`, `@` + //~| ERROR the `Self` constructor can only be used with + fn bar(&'static mur Self) {} + //~^ ERROR unexpected lifetime + //~| ERROR expected identifier, found keyword `Self` + //~| ERROR expected one of `:`, `@` + //~| ERROR the `Self` constructor can only be used with + + fn baz(&mur Self @ _) {} + //~^ ERROR expected one of `:`, `@` +} + +fn main() {} |