rust/src/test/ui/let-else/let-else-bool-binop-init.stderr

25 lines
730 B
Plaintext
Raw Normal View History

2021-08-01 19:18:50 -05:00
error: a `&&` expression cannot be directly assigned in `let...else`
--> $DIR/let-else-bool-binop-init.rs:6:16
|
LL | let true = true && false else { return };
| ^^^^^^^^^^^^^
|
help: wrap the expression in parenthesis
|
LL | let true = (true && false) else { return };
| + +
error: a `||` expression cannot be directly assigned in `let...else`
--> $DIR/let-else-bool-binop-init.rs:7:16
|
LL | let true = true || false else { return };
| ^^^^^^^^^^^^^
|
help: wrap the expression in parenthesis
|
LL | let true = (true || false) else { return };
| + +
error: aborting due to 2 previous errors