1
1
error[E0408]: variable `Ban` is not bound in all patterns
2
- --> $DIR/binding-typo-2.rs:13 :9
2
+ --> $DIR/binding-typo-2.rs:14 :9
3
3
|
4
4
LL | (Foo, Bar) | (Ban, Foo) => {}
5
5
| ^^^^^^^^^^ --- variable not in all patterns
@@ -13,7 +13,7 @@ LL + (Foo, Bar) | (Bar, Foo) => {}
13
13
|
14
14
15
15
error[E0408]: variable `Ban` is not bound in all patterns
16
- --> $DIR/binding-typo-2.rs:24 :9
16
+ --> $DIR/binding-typo-2.rs:25 :9
17
17
|
18
18
LL | (Foo, _) | (Ban, Foo) => {}
19
19
| ^^^^^^^^ --- variable not in all patterns
@@ -27,7 +27,7 @@ LL + (Foo, _) | (Bar, Foo) => {}
27
27
|
28
28
29
29
error[E0408]: variable `Non` is not bound in all patterns
30
- --> $DIR/binding-typo-2.rs:43 :15
30
+ --> $DIR/binding-typo-2.rs:44 :15
31
31
|
32
32
LL | Non | None => {}
33
33
| --- ^^^^ pattern doesn't bind `Non`
@@ -40,7 +40,7 @@ LL | None | None => {}
40
40
| +
41
41
42
42
error[E0408]: variable `Non` is not bound in all patterns
43
- --> $DIR/binding-typo-2.rs:53 :15
43
+ --> $DIR/binding-typo-2.rs:54 :15
44
44
|
45
45
LL | Non | Some(_) => {}
46
46
| --- ^^^^^^^ pattern doesn't bind `Non`
@@ -54,7 +54,7 @@ LL + core::option::Option::None | Some(_) => {}
54
54
|
55
55
56
56
error[E0408]: variable `Ban` is not bound in all patterns
57
- --> $DIR/binding-typo-2.rs:68 :9
57
+ --> $DIR/binding-typo-2.rs:69 :9
58
58
|
59
59
LL | (Foo, _) | (Ban, Foo) => {}
60
60
| ^^^^^^^^ --- variable not in all patterns
@@ -78,7 +78,7 @@ LL + (Foo, _) | (Bat, Foo) => {}
78
78
|
79
79
80
80
error[E0408]: variable `Ban` is not bound in all patterns
81
- --> $DIR/binding-typo-2.rs:85 :9
81
+ --> $DIR/binding-typo-2.rs:86 :9
82
82
|
83
83
LL | (Foo, _) | (Ban, Foo) => {}
84
84
| ^^^^^^^^ --- variable not in all patterns
@@ -97,7 +97,7 @@ LL + (Foo, _) | (Bat, Foo) => {}
97
97
|
98
98
99
99
error: variable `Ban` is assigned to, but never used
100
- --> $DIR/binding-typo-2.rs:13 :23
100
+ --> $DIR/binding-typo-2.rs:14 :23
101
101
|
102
102
LL | (Foo, Bar) | (Ban, Foo) => {}
103
103
| ^^^
@@ -115,7 +115,7 @@ LL + (Foo, Bar) | (Lol::Bar, Foo) => {}
115
115
|
116
116
117
117
error: variable `Ban` is assigned to, but never used
118
- --> $DIR/binding-typo-2.rs:24 :21
118
+ --> $DIR/binding-typo-2.rs:25 :21
119
119
|
120
120
LL | (Foo, _) | (Ban, Foo) => {}
121
121
| ^^^
@@ -128,7 +128,7 @@ LL + (Foo, _) | (Lol::Bar, Foo) => {}
128
128
|
129
129
130
130
error: unused variable: `Non`
131
- --> $DIR/binding-typo-2.rs:36 :9
131
+ --> $DIR/binding-typo-2.rs:37 :9
132
132
|
133
133
LL | Non => {}
134
134
| ^^^
@@ -144,7 +144,7 @@ LL + std::prelude::v1::None => {}
144
144
|
145
145
146
146
error: unused variable: `Non`
147
- --> $DIR/binding-typo-2.rs:43 :9
147
+ --> $DIR/binding-typo-2.rs:44 :9
148
148
|
149
149
LL | Non | None => {}
150
150
| ^^^
@@ -160,7 +160,7 @@ LL + std::prelude::v1::None | None => {}
160
160
|
161
161
162
162
error: unused variable: `Non`
163
- --> $DIR/binding-typo-2.rs:53 :9
163
+ --> $DIR/binding-typo-2.rs:54 :9
164
164
|
165
165
LL | Non | Some(_) => {}
166
166
| ^^^
@@ -176,7 +176,7 @@ LL + std::prelude::v1::None | Some(_) => {}
176
176
|
177
177
178
178
error: variable `Ban` is assigned to, but never used
179
- --> $DIR/binding-typo-2.rs:68 :21
179
+ --> $DIR/binding-typo-2.rs:69 :21
180
180
|
181
181
LL | (Foo, _) | (Ban, Foo) => {}
182
182
| ^^^
@@ -189,7 +189,7 @@ LL + (Foo, _) | (Lol::Bar, Foo) => {}
189
189
|
190
190
191
191
error: variable `Ban` is assigned to, but never used
192
- --> $DIR/binding-typo-2.rs:85 :21
192
+ --> $DIR/binding-typo-2.rs:86 :21
193
193
|
194
194
LL | (Foo, _) | (Ban, Foo) => {}
195
195
| ^^^
@@ -202,7 +202,7 @@ LL + (Foo, _) | (Lol::Bar, Foo) => {}
202
202
|
203
203
204
204
error: unused variable: `Ban`
205
- --> $DIR/binding-typo-2.rs:97 :10
205
+ --> $DIR/binding-typo-2.rs:98 :10
206
206
|
207
207
LL | (Ban, _) => {}
208
208
| ^^^
@@ -218,7 +218,7 @@ LL + (Lol::Bar, _) => {}
218
218
|
219
219
220
220
error: unused variable: `Ban`
221
- --> $DIR/binding-typo-2.rs:103 :9
221
+ --> $DIR/binding-typo-2.rs:104 :9
222
222
|
223
223
LL | Ban => {}
224
224
| ^^^
@@ -233,6 +233,21 @@ LL - Ban => {}
233
233
LL + Bay => {}
234
234
|
235
235
236
- error: aborting due to 15 previous errors
236
+ error: unused variable: `Batery`
237
+ --> $DIR/binding-typo-2.rs:110:9
238
+ |
239
+ LL | Batery => {}
240
+ | ^^^^^^
241
+ |
242
+ help: if this is intentional, prefix it with an underscore
243
+ |
244
+ LL | _Batery => {}
245
+ | +
246
+ help: you might have meant to pattern match on the similarly named constant `Battery`
247
+ |
248
+ LL | Battery => {}
249
+ | +
250
+
251
+ error: aborting due to 16 previous errors
237
252
238
253
For more information about this error, try `rustc --explain E0408`.
0 commit comments