2017-12-10 13:47:55 -06:00
|
|
|
error[E0408]: variable `a` is not bound in all patterns
|
2019-08-09 04:43:26 -05:00
|
|
|
--> $DIR/resolve-inconsistent-names.rs:13:12
|
2017-12-10 13:47:55 -06:00
|
|
|
|
|
2019-03-09 06:03:44 -06:00
|
|
|
LL | a | b => {}
|
2017-12-10 13:47:55 -06:00
|
|
|
| - ^ pattern doesn't bind `a`
|
|
|
|
| |
|
|
|
|
| variable not in all patterns
|
|
|
|
|
|
|
|
error[E0408]: variable `b` is not bound in all patterns
|
2019-08-09 04:43:26 -05:00
|
|
|
--> $DIR/resolve-inconsistent-names.rs:13:8
|
2017-12-10 13:47:55 -06:00
|
|
|
|
|
2019-03-09 06:03:44 -06:00
|
|
|
LL | a | b => {}
|
2017-12-10 13:47:55 -06:00
|
|
|
| ^ - variable not in all patterns
|
|
|
|
| |
|
|
|
|
| pattern doesn't bind `b`
|
|
|
|
|
2019-08-09 04:43:26 -05:00
|
|
|
error[E0408]: variable `A` is not bound in all patterns
|
|
|
|
--> $DIR/resolve-inconsistent-names.rs:19:18
|
|
|
|
|
|
|
|
|
LL | (A, B) | (ref B, c) | (c, A) => ()
|
|
|
|
| - ^^^^^^^^^^ - variable not in all patterns
|
|
|
|
| | |
|
|
|
|
| | pattern doesn't bind `A`
|
|
|
|
| variable not in all patterns
|
|
|
|
|
|
2019-08-09 15:21:45 -05:00
|
|
|
help: if you meant to match on a variant or a `const` item, consider making the path in the pattern qualified: `?::A`
|
2019-08-09 04:43:26 -05:00
|
|
|
--> $DIR/resolve-inconsistent-names.rs:19:10
|
|
|
|
|
|
|
|
|
LL | (A, B) | (ref B, c) | (c, A) => ()
|
|
|
|
| ^
|
|
|
|
|
|
|
|
error[E0408]: variable `B` is not bound in all patterns
|
|
|
|
--> $DIR/resolve-inconsistent-names.rs:19:31
|
|
|
|
|
|
|
|
|
LL | (A, B) | (ref B, c) | (c, A) => ()
|
|
|
|
| - - ^^^^^^ pattern doesn't bind `B`
|
|
|
|
| | |
|
|
|
|
| | variable not in all patterns
|
|
|
|
| variable not in all patterns
|
|
|
|
|
|
|
|
error[E0408]: variable `c` is not bound in all patterns
|
|
|
|
--> $DIR/resolve-inconsistent-names.rs:19:9
|
|
|
|
|
|
|
|
|
LL | (A, B) | (ref B, c) | (c, A) => ()
|
|
|
|
| ^^^^^^ - - variable not in all patterns
|
|
|
|
| | |
|
|
|
|
| | variable not in all patterns
|
|
|
|
| pattern doesn't bind `c`
|
|
|
|
|
|
|
|
error[E0409]: variable `B` is bound in inconsistent ways within the same match arm
|
|
|
|
--> $DIR/resolve-inconsistent-names.rs:19:23
|
|
|
|
|
|
|
|
|
LL | (A, B) | (ref B, c) | (c, A) => ()
|
|
|
|
| - ^ bound in different ways
|
|
|
|
| |
|
|
|
|
| first binding
|
|
|
|
|
|
|
|
error[E0408]: variable `CONST1` is not bound in all patterns
|
|
|
|
--> $DIR/resolve-inconsistent-names.rs:30:23
|
|
|
|
|
|
|
|
|
LL | (CONST1, _) | (_, Const2) => ()
|
|
|
|
| ------ ^^^^^^^^^^^ pattern doesn't bind `CONST1`
|
|
|
|
| |
|
|
|
|
| variable not in all patterns
|
|
|
|
|
|
2019-08-09 15:21:45 -05:00
|
|
|
help: if you meant to match on a variant or a `const` item, consider making the path in the pattern qualified: `?::CONST1`
|
2019-08-09 04:43:26 -05:00
|
|
|
--> $DIR/resolve-inconsistent-names.rs:30:10
|
|
|
|
|
|
|
|
|
LL | (CONST1, _) | (_, Const2) => ()
|
|
|
|
| ^^^^^^
|
|
|
|
|
|
|
|
error[E0408]: variable `Const2` is not bound in all patterns
|
|
|
|
--> $DIR/resolve-inconsistent-names.rs:30:9
|
|
|
|
|
|
|
|
|
LL | (CONST1, _) | (_, Const2) => ()
|
|
|
|
| ^^^^^^^^^^^ ------ variable not in all patterns
|
|
|
|
| |
|
|
|
|
| pattern doesn't bind `Const2`
|
|
|
|
|
|
2019-08-09 15:21:45 -05:00
|
|
|
help: if you meant to match on a variant or a `const` item, consider making the path in the pattern qualified: `?::Const2`
|
2019-08-09 04:43:26 -05:00
|
|
|
--> $DIR/resolve-inconsistent-names.rs:30:27
|
|
|
|
|
|
|
|
|
LL | (CONST1, _) | (_, Const2) => ()
|
|
|
|
| ^^^^^^
|
|
|
|
|
|
|
|
error[E0308]: mismatched types
|
|
|
|
--> $DIR/resolve-inconsistent-names.rs:19:19
|
|
|
|
|
|
2019-12-30 02:08:18 -06:00
|
|
|
LL | match x {
|
|
|
|
| - this expression has type `(E, E)`
|
2019-08-09 04:43:26 -05:00
|
|
|
LL | (A, B) | (ref B, c) | (c, A) => ()
|
2020-02-24 22:30:43 -06:00
|
|
|
| - ^^^^^ expected enum `E`, found `&E`
|
|
|
|
| |
|
|
|
|
| first introduced with type `E` here
|
|
|
|
|
|
|
|
|
= note: in the same arm, a binding must have the same type in all alternatives
|
2019-08-09 04:43:26 -05:00
|
|
|
|
|
|
|
error: aborting due to 9 previous errors
|
2017-12-10 13:47:55 -06:00
|
|
|
|
2019-08-09 04:43:26 -05:00
|
|
|
Some errors have detailed explanations: E0308, E0408, E0409.
|
|
|
|
For more information about an error, try `rustc --explain E0308`.
|