fork/rust

git clone https://git.julia.blue/fork/rust

borsAuto merge of #67350 - Mark-Simulacrum:stable-next, r=Mark-Simulacrum73528e339aa

1.40.0
897 B36 linesraw
1error[E0308]: mismatched types
2  --> $DIR/match-needing-semi.rs:8:13
3   |
4LL | /     match 3 {
5LL | |         4 => 1,
6LL | |         3 => {
7LL | |             2
8   | |             ^ expected (), found integer
9LL | |         }
10LL | |         _ => 2
11LL | |     }
12   | |     -- help: consider using a semicolon here
13   | |_____|
14   |       expected this to be `()`
15   |
16   = note: expected type `()`
17              found type `{integer}`
18
19error[E0308]: mismatched types
20  --> $DIR/match-needing-semi.rs:12:5
21   |
22LL | /     match 3 {
23LL | |         4 => 1,
24LL | |         3 => 2,
25LL | |         _ => 2
26LL | |     }
27   | |     ^- help: consider using a semicolon here
28   | |_____|
29   |       expected (), found integer
30   |
31   = note: expected type `()`
32              found type `{integer}`
33
34error: aborting due to 2 previous errors
35
36For more information about this error, try `rustc --explain E0308`.