about summary refs log tree commit diff
path: root/tests/ui/reachable/expr_match.stderr
blob: ae202a6e0c34a09889ce7f3b4825c151798a1411 (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
38
39
40
41
42
43
44
45
46
47
48
49
error: unreachable statement
  --> $DIR/expr_match.rs:8:5
   |
LL |     match () { () => return }
   |     ------------------------- any code following this `match` expression is unreachable, as all arms diverge
LL |     println!("I am dead");
   |     ^^^^^^^^^^^^^^^^^^^^^ unreachable statement
   |
note: the lint level is defined here
  --> $DIR/expr_match.rs:4:9
   |
LL | #![deny(unreachable_code)]
   |         ^^^^^^^^^^^^^^^^
   = note: this error originates in the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)

error: unreachable statement
  --> $DIR/expr_match.rs:19:5
   |
LL |     match () { () if false => return, () => return }
   |     ------------------------------------------------ any code following this `match` expression is unreachable, as all arms diverge
LL |     println!("I am dead");
   |     ^^^^^^^^^^^^^^^^^^^^^ unreachable statement
   |
   = note: this error originates in the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)

error: unreachable expression
  --> $DIR/expr_match.rs:25:25
   |
LL |         () if return => (),
   |               ------    ^^ unreachable expression
   |               |
   |               any code following this expression is unreachable

error: unreachable statement
  --> $DIR/expr_match.rs:29:5
   |
LL | /     match () {
LL | |         () if return => (),
LL | |
LL | |         () => return,
LL | |     }
   | |_____- any code following this `match` expression is unreachable, as all arms diverge
LL |       println!("I am dead");
   |       ^^^^^^^^^^^^^^^^^^^^^ unreachable statement
   |
   = note: this error originates in the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)

error: aborting due to 4 previous errors