rust/tests/ui/or-patterns/multiple-pattern-typo.stderr
Esteban Küber 692bc344d5 Make parse error suggestions verbose and fix spans
Go over all structured parser suggestions and make them verbose style.

When suggesting to add or remove delimiters, turn them into multiple suggestion parts.
2024-07-12 03:02:57 +00:00

92 lines
2.4 KiB
Plaintext

error: unexpected token `||` in pattern
--> $DIR/multiple-pattern-typo.rs:7:15
|
LL | 1 | 2 || 3 => (),
| - ^^
| |
| while parsing this or-pattern starting here
|
help: use a single `|` to separate multiple alternative patterns
|
LL | 1 | 2 | 3 => (),
| ~
error: unexpected token `||` in pattern
--> $DIR/multiple-pattern-typo.rs:12:16
|
LL | (1 | 2 || 3) => (),
| - ^^
| |
| while parsing this or-pattern starting here
|
help: use a single `|` to separate multiple alternative patterns
|
LL | (1 | 2 | 3) => (),
| ~
error: unexpected token `||` in pattern
--> $DIR/multiple-pattern-typo.rs:17:16
|
LL | (1 | 2 || 3,) => (),
| - ^^
| |
| while parsing this or-pattern starting here
|
help: use a single `|` to separate multiple alternative patterns
|
LL | (1 | 2 | 3,) => (),
| ~
error: unexpected token `||` in pattern
--> $DIR/multiple-pattern-typo.rs:24:18
|
LL | TS(1 | 2 || 3) => (),
| - ^^
| |
| while parsing this or-pattern starting here
|
help: use a single `|` to separate multiple alternative patterns
|
LL | TS(1 | 2 | 3) => (),
| ~
error: unexpected token `||` in pattern
--> $DIR/multiple-pattern-typo.rs:31:23
|
LL | NS { f: 1 | 2 || 3 } => (),
| - ^^
| |
| while parsing this or-pattern starting here
|
help: use a single `|` to separate multiple alternative patterns
|
LL | NS { f: 1 | 2 | 3 } => (),
| ~
error: unexpected token `||` in pattern
--> $DIR/multiple-pattern-typo.rs:36:16
|
LL | [1 | 2 || 3] => (),
| - ^^
| |
| while parsing this or-pattern starting here
|
help: use a single `|` to separate multiple alternative patterns
|
LL | [1 | 2 | 3] => (),
| ~
error: unexpected token `||` in pattern
--> $DIR/multiple-pattern-typo.rs:41:9
|
LL | || 1 | 2 | 3 => (),
| ^^
|
help: use a single `|` to separate multiple alternative patterns
|
LL | | 1 | 2 | 3 => (),
| ~
error: aborting due to 7 previous errors