Fix expected parse error
This commit is contained in:
parent
471370a16b
commit
83e43bb728
8 changed files with 9 additions and 8 deletions
|
@ -11,5 +11,5 @@
|
|||
// compile-flags: -Z parse-only
|
||||
|
||||
fn main() {
|
||||
let x: [isize 3]; //~ ERROR expected one of `(`, `+`, `::`, `;`, `<`, or `]`, found `3`
|
||||
let x: [isize 3]; //~ ERROR expected one of `!`, `(`, `+`, `::`, `;`, `<`, or `]`, found `3`
|
||||
}
|
||||
|
|
|
@ -10,4 +10,4 @@
|
|||
|
||||
// compile-flags: -Z parse-only
|
||||
|
||||
impl Foo; //~ ERROR expected one of `(`, `+`, `::`, `<`, `for`, `where`, or `{`, found `;`
|
||||
impl Foo; //~ ERROR expected one of `!`, `(`, `+`, `::`, `<`, `for`, `where`, or `{`, found `;`
|
||||
|
|
|
@ -15,7 +15,7 @@ struct S {
|
|||
}
|
||||
|
||||
impl Cmp, ToString for S {
|
||||
//~^ ERROR: expected one of `(`, `+`, `::`, `<`, `for`, `where`, or `{`, found `,`
|
||||
//~^ ERROR: expected one of `!`, `(`, `+`, `::`, `<`, `for`, `where`, or `{`, found `,`
|
||||
fn eq(&&other: S) { false }
|
||||
fn to_string(&self) -> String { "hi".to_string() }
|
||||
}
|
||||
|
|
|
@ -10,4 +10,5 @@
|
|||
|
||||
// compile-flags: -Z parse-only
|
||||
|
||||
type closure = Box<lt/fn()>; //~ ERROR expected one of `(`, `+`, `,`, `::`, `<`, or `>`, found `/`
|
||||
type closure = Box<lt/fn()>;
|
||||
//~^ ERROR expected one of `!`, `(`, `+`, `,`, `::`, `<`, or `>`, found `/`
|
||||
|
|
|
@ -10,4 +10,4 @@
|
|||
|
||||
// compile-flags: -Z parse-only
|
||||
|
||||
type v = [isize * 3]; //~ ERROR expected one of `(`, `+`, `::`, `;`, `<`, or `]`, found `*`
|
||||
type v = [isize * 3]; //~ ERROR expected one of `!`, `(`, `+`, `::`, `;`, `<`, or `]`, found `*`
|
||||
|
|
|
@ -12,4 +12,4 @@
|
|||
|
||||
type v = [mut isize];
|
||||
//~^ ERROR expected identifier, found keyword `mut`
|
||||
//~^^ ERROR expected one of `(`, `+`, `::`, `;`, `<`, or `]`, found `isize`
|
||||
//~^^ ERROR expected one of `!`, `(`, `+`, `::`, `;`, `<`, or `]`, found `isize`
|
||||
|
|
|
@ -10,4 +10,4 @@
|
|||
|
||||
// compile-flags: -Z parse-only
|
||||
|
||||
type bptr = &lifetime/isize; //~ ERROR expected one of `(`, `+`, `::`, `;`, or `<`, found `/`
|
||||
type bptr = &lifetime/isize; //~ ERROR expected one of `!`, `(`, `+`, `::`, `;`, or `<`, found `/`
|
||||
|
|
|
@ -12,4 +12,4 @@
|
|||
|
||||
type mut_box = Box<mut isize>;
|
||||
//~^ ERROR expected identifier, found keyword `mut`
|
||||
//~^^ ERROR expected one of `(`, `+`, `,`, `::`, `<`, or `>`, found `isize`
|
||||
//~^^ ERROR expected one of `!`, `(`, `+`, `,`, `::`, `<`, or `>`, found `isize`
|
||||
|
|
Loading…
Reference in a new issue