rust/tests/ui/rfcs/rfc-2294-if-let-guard/parens.stderr

53 lines
1.4 KiB
Plaintext
Raw Normal View History

2023-08-24 03:41:30 -05:00
error: expected expression, found `let` statement
--> $DIR/parens.rs:10:16
|
LL | () if (let 0 = 1) => {}
| ^^^
error: expected expression, found `let` statement
--> $DIR/parens.rs:12:18
|
LL | () if (((let 0 = 1))) => {}
| ^^^
error: expected expression, found `let` statement
--> $DIR/parens.rs:20:16
|
LL | () if (let 0 = 1) => {}
| ^^^
error: expected expression, found `let` statement
--> $DIR/parens.rs:23:18
|
LL | () if (((let 0 = 1))) => {}
| ^^^
error: `let` expressions are not supported here
--> $DIR/parens.rs:20:16
|
LL | () if (let 0 = 1) => {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
--> $DIR/parens.rs:20:16
|
LL | () if (let 0 = 1) => {}
| ^^^^^^^^^
error: `let` expressions are not supported here
--> $DIR/parens.rs:23:18
|
LL | () if (((let 0 = 1))) => {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
--> $DIR/parens.rs:23:18
|
LL | () if (((let 0 = 1))) => {}
| ^^^^^^^^^
error: aborting due to 6 previous errors