diff options
Diffstat (limited to 'src/test/parse-fail')
| -rw-r--r-- | src/test/parse-fail/issue-21153.rs | 5 | ||||
| -rw-r--r-- | src/test/parse-fail/trait-pub-assoc-const.rs | 2 | ||||
| -rw-r--r-- | src/test/parse-fail/trait-pub-assoc-ty.rs | 2 | ||||
| -rw-r--r-- | src/test/parse-fail/trait-pub-method.rs | 2 |
4 files changed, 5 insertions, 6 deletions
diff --git a/src/test/parse-fail/issue-21153.rs b/src/test/parse-fail/issue-21153.rs index c03e0ef7321..b6d95ffb911 100644 --- a/src/test/parse-fail/issue-21153.rs +++ b/src/test/parse-fail/issue-21153.rs @@ -10,7 +10,6 @@ // compile-flags: -Z parse-only -trait MyTrait<T>: Iterator { - Item = T; //~ ERROR expected one of `!` or `::`, found `=` - //~| ERROR expected item, found `=` +trait MyTrait<T>: Iterator { //~ ERROR missing `fn`, `type`, or `const` + Item = T; } diff --git a/src/test/parse-fail/trait-pub-assoc-const.rs b/src/test/parse-fail/trait-pub-assoc-const.rs index adce0d7bbf4..6bc24e2081d 100644 --- a/src/test/parse-fail/trait-pub-assoc-const.rs +++ b/src/test/parse-fail/trait-pub-assoc-const.rs @@ -10,7 +10,7 @@ trait Foo { pub const Foo: u32; - //~^ ERROR expected one of `const`, `extern`, `fn`, `type`, or `unsafe`, found `pub` + //~^ ERROR expected one of `const`, `extern`, `fn`, `type`, `unsafe`, or `}`, found `pub` } fn main() {} diff --git a/src/test/parse-fail/trait-pub-assoc-ty.rs b/src/test/parse-fail/trait-pub-assoc-ty.rs index dab6c433aba..493ff087eaf 100644 --- a/src/test/parse-fail/trait-pub-assoc-ty.rs +++ b/src/test/parse-fail/trait-pub-assoc-ty.rs @@ -10,7 +10,7 @@ trait Foo { pub type Foo; - //~^ ERROR expected one of `const`, `extern`, `fn`, `type`, or `unsafe`, found `pub` + //~^ ERROR expected one of `const`, `extern`, `fn`, `type`, `unsafe`, or `}`, found `pub` } fn main() {} diff --git a/src/test/parse-fail/trait-pub-method.rs b/src/test/parse-fail/trait-pub-method.rs index 7cb9363830c..c2ee3c31d88 100644 --- a/src/test/parse-fail/trait-pub-method.rs +++ b/src/test/parse-fail/trait-pub-method.rs @@ -10,7 +10,7 @@ trait Foo { pub fn foo(); - //~^ ERROR expected one of `const`, `extern`, `fn`, `type`, or `unsafe`, found `pub` + //~^ ERROR expected one of `const`, `extern`, `fn`, `type`, `unsafe`, or `}`, found `pub` } fn main() {} |
