1 #![feature(let_chains)]
6 let Some(n) = opt else {
9 let Some(n) = opt && n == 1 else {
10 //~^ ERROR a `&&` expression cannot be directly assigned in `let...else`
11 //~| ERROR mismatched types
12 //~| ERROR mismatched types
15 let Some(n) = opt && let another = n else {
16 //~^ ERROR a `&&` expression cannot be directly assigned in `let...else`
17 //~| ERROR `let` expressions are not supported here
18 //~| ERROR mismatched types
19 //~| ERROR mismatched types
20 //~| ERROR expected expression, found `let` statement
24 if let Some(n) = opt else {
25 //~^ ERROR this `if` expression is missing a block after the condition
28 if let Some(n) = opt && n == 1 else {
29 //~^ ERROR this `if` expression is missing a block after the condition
32 if let Some(n) = opt && let another = n else {
33 //~^ ERROR this `if` expression is missing a block after the condition
38 while let Some(n) = opt else {
39 //~^ ERROR expected `{`, found keyword `else`
44 while let Some(n) = opt && n == 1 else {
45 //~^ ERROR expected `{`, found keyword `else`
50 while let Some(n) = opt && let another = n else {
51 //~^ ERROR expected `{`, found keyword `else`