Skip to content

Commit 3ff1d6b

Browse files
committed
Fix tests
1 parent 5b95df4 commit 3ff1d6b

13 files changed

+33
-33
lines changed

src/test/ui/did_you_mean/issue-40396.stderr

+2-2
Original file line numberDiff line numberDiff line change
@@ -31,11 +31,11 @@ help: use `::<...>` instead of `<...>` to specify type or const arguments
3131
LL | (0..13).collect::<Vec<i32>();
3232
| ++
3333

34-
error: expected one of `!`, `.`, `::`, `;`, `?`, `{`, or an operator, found `,`
34+
error: expected one of `!`, `.`, `::`, `;`, `?`, `else`, `{`, or an operator, found `,`
3535
--> $DIR/issue-40396.rs:11:43
3636
|
3737
LL | let x = std::collections::HashMap<i128, i128>::new();
38-
| ^ expected one of 7 possible tokens
38+
| ^ expected one of 8 possible tokens
3939
|
4040
help: use `::<...>` instead of `<...>` to specify type or const arguments
4141
|

src/test/ui/parser/attr-stmt-expr-attr-bad.stderr

+8-8
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,11 @@ error: expected expression, found `]`
1212
LL | #[cfg(FALSE)] fn e() { let _ = [#[attr]]; }
1313
| ^ expected expression
1414

15-
error: expected one of `!`, `.`, `::`, `;`, `?`, `{`, or an operator, found `#`
15+
error: expected one of `!`, `.`, `::`, `;`, `?`, `else`, `{`, or an operator, found `#`
1616
--> $DIR/attr-stmt-expr-attr-bad.rs:9:35
1717
|
1818
LL | #[cfg(FALSE)] fn e() { let _ = foo#[attr](); }
19-
| ^ expected one of 7 possible tokens
19+
| ^ expected one of 8 possible tokens
2020

2121
error: an inner attribute is not permitted in this context
2222
--> $DIR/attr-stmt-expr-attr-bad.rs:11:36
@@ -70,11 +70,11 @@ LL | #[cfg(FALSE)] fn e() { let _ = -#![attr] 0; }
7070
|
7171
= note: inner attributes, like `#![no_std]`, annotate the item enclosing them, and are usually found at the beginning of source files. Outer attributes, like `#[test]`, annotate the item following them.
7272

73-
error: expected one of `!`, `.`, `::`, `;`, `?`, `{`, or an operator, found `#`
73+
error: expected one of `!`, `.`, `::`, `;`, `?`, `else`, `{`, or an operator, found `#`
7474
--> $DIR/attr-stmt-expr-attr-bad.rs:23:34
7575
|
7676
LL | #[cfg(FALSE)] fn e() { let _ = x #![attr] as Y; }
77-
| ^ expected one of 7 possible tokens
77+
| ^ expected one of 8 possible tokens
7878

7979
error: an inner attribute is not permitted in this context
8080
--> $DIR/attr-stmt-expr-attr-bad.rs:25:35
@@ -372,23 +372,23 @@ error: unexpected token: `#`
372372
LL | #[cfg(FALSE)] fn e() { let _ = x.#![attr]foo(); }
373373
| ^
374374

375-
error: expected one of `.`, `;`, `?`, or an operator, found `#`
375+
error: expected one of `.`, `;`, `?`, `else`, or an operator, found `#`
376376
--> $DIR/attr-stmt-expr-attr-bad.rs:100:34
377377
|
378378
LL | #[cfg(FALSE)] fn e() { let _ = x.#![attr]foo(); }
379-
| ^ expected one of `.`, `;`, `?`, or an operator
379+
| ^ expected one of `.`, `;`, `?`, `else`, or an operator
380380

381381
error: unexpected token: `#`
382382
--> $DIR/attr-stmt-expr-attr-bad.rs:103:34
383383
|
384384
LL | #[cfg(FALSE)] fn e() { let _ = x.#[attr]foo(); }
385385
| ^
386386

387-
error: expected one of `.`, `;`, `?`, or an operator, found `#`
387+
error: expected one of `.`, `;`, `?`, `else`, or an operator, found `#`
388388
--> $DIR/attr-stmt-expr-attr-bad.rs:103:34
389389
|
390390
LL | #[cfg(FALSE)] fn e() { let _ = x.#[attr]foo(); }
391-
| ^ expected one of `.`, `;`, `?`, or an operator
391+
| ^ expected one of `.`, `;`, `?`, `else`, or an operator
392392

393393
error: expected statement after outer attribute
394394
--> $DIR/attr-stmt-expr-attr-bad.rs:108:37

src/test/ui/parser/issue-72253.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
fn main() {
22
let a = std::process::Command::new("echo")
33
.arg("1")
4-
,arg("2") //~ ERROR expected one of `.`, `;`, `?`, or an operator, found `,`
4+
,arg("2") //~ ERROR expected one of `.`, `;`, `?`, `else`, or an operator, found `,`
55
.output();
66
}

src/test/ui/parser/issue-72253.stderr

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
error: expected one of `.`, `;`, `?`, or an operator, found `,`
1+
error: expected one of `.`, `;`, `?`, `else`, or an operator, found `,`
22
--> $DIR/issue-72253.rs:4:9
33
|
44
LL | .arg("1")
5-
| - expected one of `.`, `;`, `?`, or an operator
5+
| - expected one of `.`, `;`, `?`, `else`, or an operator
66
LL | ,arg("2")
77
| ^ unexpected token
88

src/test/ui/parser/issue-84117.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@ fn main() {
22
let outer_local:e_outer<&str, { let inner_local:e_inner<&str, }
33
//~^ ERROR expected one of `>`, a const expression
44
//~| ERROR expected one of `>`, a const expression, lifetime, or type, found `}`
5-
//~| ERROR expected one of `!`, `.`, `::`, `;`, `?`, `{`, or an operator, found `,`
6-
//~| ERROR expected one of `!`, `.`, `::`, `;`, `?`, `{`, or an operator, found `,`
7-
//~| ERROR expected one of `!`, `.`, `::`, `;`, `?`, `{`, or an operator, found `,`
5+
//~| ERROR expected one of `!`, `.`, `::`, `;`, `?`, `else`, `{`, or an operator, found `,`
6+
//~| ERROR expected one of `!`, `.`, `::`, `;`, `?`, `else`, `{`, or an operator, found `,`
7+
//~| ERROR expected one of `!`, `.`, `::`, `;`, `?`, `else`, `{`, or an operator, found `,`
88
}
99
//~^ ERROR expected one of `,`, `:`, `=`, or `>`, found `}`

src/test/ui/parser/issue-84117.stderr

+6-6
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,11 @@ LL | let outer_local:e_outer<&str, { let inner_local:e_inner<&str, }
77
| | help: use `=` if you meant to assign
88
| while parsing the type for `inner_local`
99

10-
error: expected one of `!`, `.`, `::`, `;`, `?`, `{`, or an operator, found `,`
10+
error: expected one of `!`, `.`, `::`, `;`, `?`, `else`, `{`, or an operator, found `,`
1111
--> $DIR/issue-84117.rs:2:65
1212
|
1313
LL | let outer_local:e_outer<&str, { let inner_local:e_inner<&str, }
14-
| ^ expected one of 7 possible tokens
14+
| ^ expected one of 8 possible tokens
1515

1616
error: expected one of `,`, `:`, `=`, or `>`, found `}`
1717
--> $DIR/issue-84117.rs:8:1
@@ -33,17 +33,17 @@ LL | let outer_local:e_outer<&str, { let inner_local:e_inner<&str, }
3333
| | help: use `=` if you meant to assign
3434
| while parsing the type for `inner_local`
3535

36-
error: expected one of `!`, `.`, `::`, `;`, `?`, `{`, or an operator, found `,`
36+
error: expected one of `!`, `.`, `::`, `;`, `?`, `else`, `{`, or an operator, found `,`
3737
--> $DIR/issue-84117.rs:2:65
3838
|
3939
LL | let outer_local:e_outer<&str, { let inner_local:e_inner<&str, }
40-
| ^ expected one of 7 possible tokens
40+
| ^ expected one of 8 possible tokens
4141

42-
error: expected one of `!`, `.`, `::`, `;`, `?`, `{`, or an operator, found `,`
42+
error: expected one of `!`, `.`, `::`, `;`, `?`, `else`, `{`, or an operator, found `,`
4343
--> $DIR/issue-84117.rs:2:33
4444
|
4545
LL | let outer_local:e_outer<&str, { let inner_local:e_inner<&str, }
46-
| ^ expected one of 7 possible tokens
46+
| ^ expected one of 8 possible tokens
4747

4848
error: aborting due to 6 previous errors
4949

src/test/ui/parser/macro/issue-37234.stderr

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
error: expected one of `.`, `;`, `?`, or an operator, found `""`
1+
error: expected one of `.`, `;`, `?`, `else`, or an operator, found `""`
22
--> $DIR/issue-37234.rs:3:19
33
|
44
LL | let x = 5 "";
5-
| ^^ expected one of `.`, `;`, `?`, or an operator
5+
| ^^ expected one of `.`, `;`, `?`, `else`, or an operator
66
...
77
LL | failed!();
88
| ---------- in this macro invocation

src/test/ui/parser/missing-semicolon.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
macro_rules! m {
22
($($e1:expr),*; $($e2:expr),*) => {
3-
$( let x = $e1 )*; //~ ERROR expected one of `.`, `;`, `?`, or
3+
$( let x = $e1 )*; //~ ERROR expected one of `.`, `;`, `?`, `else`, or
44
$( println!("{}", $e2) )*;
55
}
66
}

src/test/ui/parser/missing-semicolon.stderr

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
error: expected one of `.`, `;`, `?`, or an operator, found keyword `let`
1+
error: expected one of `.`, `;`, `?`, `else`, or an operator, found keyword `let`
22
--> $DIR/missing-semicolon.rs:3:12
33
|
44
LL | $( let x = $e1 )*;
5-
| ^^^ expected one of `.`, `;`, `?`, or an operator
5+
| ^^^ expected one of `.`, `;`, `?`, `else`, or an operator
66
...
77
LL | fn main() { m!(0, 0; 0, 0); }
88
| --------------- in this macro invocation

src/test/ui/parser/range-3.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,5 @@
22

33
pub fn main() {
44
let r = 1..2..3;
5-
//~^ ERROR expected one of `.`, `;`, `?`, or an operator, found `..`
5+
//~^ ERROR expected one of `.`, `;`, `?`, `else`, or an operator, found `..`
66
}

src/test/ui/parser/range-3.stderr

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
error: expected one of `.`, `;`, `?`, or an operator, found `..`
1+
error: expected one of `.`, `;`, `?`, `else`, or an operator, found `..`
22
--> $DIR/range-3.rs:4:17
33
|
44
LL | let r = 1..2..3;
5-
| ^^ expected one of `.`, `;`, `?`, or an operator
5+
| ^^ expected one of `.`, `;`, `?`, `else`, or an operator
66

77
error: aborting due to previous error
88

src/test/ui/parser/range-4.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,5 @@
22

33
pub fn main() {
44
let r = ..1..2;
5-
//~^ ERROR expected one of `.`, `;`, `?`, or an operator, found `..`
5+
//~^ ERROR expected one of `.`, `;`, `?`, `else`, or an operator, found `..`
66
}

src/test/ui/parser/range-4.stderr

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
error: expected one of `.`, `;`, `?`, or an operator, found `..`
1+
error: expected one of `.`, `;`, `?`, `else`, or an operator, found `..`
22
--> $DIR/range-4.rs:4:16
33
|
44
LL | let r = ..1..2;
5-
| ^^ expected one of `.`, `;`, `?`, or an operator
5+
| ^^ expected one of `.`, `;`, `?`, `else`, or an operator
66

77
error: aborting due to previous error
88

0 commit comments

Comments
 (0)