fork/rust
git clone https://git.julia.blue/fork/rust
4560ea788cb
1.39.0
1error: struct literals are not allowed here 2 --> $DIR/E0423.rs:12:32 3 | 4LL | if let S { x: _x, y: 2 } = S { x: 1, y: 2 } { println!("Ok"); } 5 | ^^^^^^^^^^^^^^^^ 6help: surround the struct literal with parentheses 7 | 8LL | if let S { x: _x, y: 2 } = (S { x: 1, y: 2 }) { println!("Ok"); } 9 | ^ ^ 10 11error: expected expression, found `==` 12 --> $DIR/E0423.rs:14:13 13 | 14LL | if T {} == T {} { println!("Ok"); } 15 | ^^ expected expression 16 17error: struct literals are not allowed here 18 --> $DIR/E0423.rs:20:14 19 | 20LL | for _ in std::ops::Range { start: 0, end: 10 } {} 21 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 22help: surround the struct literal with parentheses 23 | 24LL | for _ in (std::ops::Range { start: 0, end: 10 }) {} 25 | ^ ^ 26 27error[E0423]: expected function, found struct `Foo` 28 --> $DIR/E0423.rs:4:13 29 | 30LL | let f = Foo(); 31 | ^^^ 32 | | 33 | did you mean `Foo { /* fields */ }`? 34 | help: a function with a similar name exists: `foo` 35 36error[E0423]: expected value, found struct `T` 37 --> $DIR/E0423.rs:14:8 38 | 39LL | if T {} == T {} { println!("Ok"); } 40 | ^--- 41 | | 42 | help: surround the struct literal with parenthesis: `(T {})` 43 44error: aborting due to 5 previous errors 45 46For more information about this error, try `rustc --explain E0423`.