summaryrefslogtreecommitdiffstats
path: root/src/test/ui/suggestions/match-needing-semi.stderr
blob: b5f01d7038c0dea23404ab2c6e620c66fabbceaa (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
error[E0308]: mismatched types
  --> $DIR/match-needing-semi.rs:7:13
   |
LL | /     match 3 {
LL | |         4 => 1,
LL | |         3 => {
LL | |             foo()
   | |             ^^^^^ expected `()`, found `i32`
LL | |         }
LL | |         _ => 2
LL | |     }
   | |_____- expected this to be `()`
   |
help: consider using a semicolon here
   |
LL |             foo();
   |                  +
help: consider using a semicolon here
   |
LL |     };
   |      +

error[E0308]: mismatched types
  --> $DIR/match-needing-semi.rs:11:5
   |
LL | /     match 3 {
LL | |         4 => 1,
LL | |         3 => 2,
LL | |         _ => 2
LL | |     }
   | |     ^- help: consider using a semicolon here
   | |_____|
   |       expected `()`, found integer

error: aborting due to 2 previous errors

For more information about this error, try `rustc --explain E0308`.