rust/tests/ui/parser/pat-recover-ranges.stderr
Lieselotte 4e0baddbbf
Recover parentheses in range patterns
Co-authored-by: León Orell Valerian Liehr <me@fmease.dev>
2024-01-03 15:27:58 +01:00

51 lines
1.0 KiB
Plaintext

error: range pattern bounds cannot have parentheses
--> $DIR/pat-recover-ranges.rs:4:13
|
LL | 0..=(1) => (),
| ^ ^
|
help: remove these parentheses
|
LL - 0..=(1) => (),
LL + 0..=1 => (),
|
error: range pattern bounds cannot have parentheses
--> $DIR/pat-recover-ranges.rs:6:9
|
LL | (-12)..=4 => (),
| ^ ^
|
help: remove these parentheses
|
LL - (-12)..=4 => (),
LL + -12..=4 => (),
|
error: range pattern bounds cannot have parentheses
--> $DIR/pat-recover-ranges.rs:8:9
|
LL | (0)..=(-4) => (),
| ^ ^
|
help: remove these parentheses
|
LL - (0)..=(-4) => (),
LL + 0..=(-4) => (),
|
error: range pattern bounds cannot have parentheses
--> $DIR/pat-recover-ranges.rs:8:15
|
LL | (0)..=(-4) => (),
| ^ ^
|
help: remove these parentheses
|
LL - (0)..=(-4) => (),
LL + (0)..=-4 => (),
|
error: aborting due to 4 previous errors