]>
Commit | Line | Data |
---|---|---|
8faf50e0 | 1 | warning[E0170]: pattern binding `A` is named the same as one of the variants of the type `E` |
0731742a | 2 | --> $DIR/issue-14221.rs:13:13 |
8faf50e0 XL |
3 | | |
4 | LL | A => "A", | |
5 | | ^ help: to match on the variant, qualify the path: `E::A` | |
46de9a89 FG |
6 | | |
7 | = note: `#[warn(bindings_with_variant_name)]` on by default | |
8faf50e0 XL |
8 | |
9 | warning[E0170]: pattern binding `B` is named the same as one of the variants of the type `E` | |
0731742a | 10 | --> $DIR/issue-14221.rs:15:13 |
8faf50e0 | 11 | | |
532ac7d7 | 12 | LL | B => "B", |
8faf50e0 XL |
13 | | ^ help: to match on the variant, qualify the path: `E::B` |
14 | ||
15 | error: unreachable pattern | |
0731742a | 16 | --> $DIR/issue-14221.rs:15:13 |
8faf50e0 XL |
17 | | |
18 | LL | A => "A", | |
19 | | - matches any value | |
532ac7d7 XL |
20 | LL | |
21 | LL | B => "B", | |
8faf50e0 XL |
22 | | ^ unreachable pattern |
23 | | | |
72b1a166 | 24 | note: the lint level is defined here |
0731742a | 25 | --> $DIR/issue-14221.rs:1:9 |
8faf50e0 XL |
26 | | |
27 | LL | #![deny(unreachable_patterns)] | |
28 | | ^^^^^^^^^^^^^^^^^^^^ | |
29 | ||
72b1a166 | 30 | error: aborting due to previous error; 2 warnings emitted |
8faf50e0 XL |
31 | |
32 | For more information about this error, try `rustc --explain E0170`. |