1
1
error: unreachable pattern
2
- --> $DIR/match-empty-exhaustive_patterns.rs:48 :9
2
+ --> $DIR/match-empty-exhaustive_patterns.rs:52 :9
3
3
|
4
4
LL | _ => {},
5
5
| ^
6
6
|
7
7
note: the lint level is defined here
8
- --> $DIR/match-empty-exhaustive_patterns.rs:4 :9
8
+ --> $DIR/match-empty-exhaustive_patterns.rs:5 :9
9
9
|
10
10
LL | #![deny(unreachable_patterns)]
11
11
| ^^^^^^^^^^^^^^^^^^^^
12
12
13
13
error: unreachable pattern
14
- --> $DIR/match-empty-exhaustive_patterns.rs:51 :9
14
+ --> $DIR/match-empty-exhaustive_patterns.rs:55 :9
15
15
|
16
16
LL | _ if false => {},
17
17
| ^
18
18
19
19
error: unreachable pattern
20
- --> $DIR/match-empty-exhaustive_patterns.rs:58 :9
20
+ --> $DIR/match-empty-exhaustive_patterns.rs:62 :9
21
21
|
22
22
LL | _ => {},
23
23
| ^
24
24
25
25
error: unreachable pattern
26
- --> $DIR/match-empty-exhaustive_patterns.rs:61 :9
26
+ --> $DIR/match-empty-exhaustive_patterns.rs:65 :9
27
27
|
28
28
LL | _ if false => {},
29
29
| ^
30
30
31
31
error: unreachable pattern
32
- --> $DIR/match-empty-exhaustive_patterns.rs:68:9
32
+ --> $DIR/match-empty-exhaustive_patterns.rs:72:9
33
+ |
34
+ LL | _ => {},
35
+ | ^
36
+
37
+ error: unreachable pattern
38
+ --> $DIR/match-empty-exhaustive_patterns.rs:75:9
39
+ |
40
+ LL | _ if false => {},
41
+ | ^
42
+
43
+ error: unreachable pattern
44
+ --> $DIR/match-empty-exhaustive_patterns.rs:82:9
33
45
|
34
46
LL | Some(_) => {}
35
47
| ^^^^^^^
36
48
37
49
error: unreachable pattern
38
- --> $DIR/match-empty-exhaustive_patterns.rs:72 :9
50
+ --> $DIR/match-empty-exhaustive_patterns.rs:86 :9
39
51
|
40
52
LL | Some(_) => {}
41
53
| ^^^^^^^
42
54
43
55
error[E0004]: non-exhaustive patterns: type `u8` is non-empty
44
- --> $DIR/match-empty-exhaustive_patterns.rs:75 :18
56
+ --> $DIR/match-empty-exhaustive_patterns.rs:89 :18
45
57
|
46
58
LL | match_empty!(0u8);
47
59
| ^^^
@@ -50,7 +62,7 @@ LL | match_empty!(0u8);
50
62
= note: the matched value is of type `u8`
51
63
52
64
error[E0004]: non-exhaustive patterns: type `NonEmptyStruct` is non-empty
53
- --> $DIR/match-empty-exhaustive_patterns.rs:77 :18
65
+ --> $DIR/match-empty-exhaustive_patterns.rs:91 :18
54
66
|
55
67
LL | struct NonEmptyStruct(bool);
56
68
| ---------------------------- `NonEmptyStruct` defined here
@@ -62,7 +74,7 @@ LL | match_empty!(NonEmptyStruct(true));
62
74
= note: the matched value is of type `NonEmptyStruct`
63
75
64
76
error[E0004]: non-exhaustive patterns: type `NonEmptyUnion1` is non-empty
65
- --> $DIR/match-empty-exhaustive_patterns.rs:79 :18
77
+ --> $DIR/match-empty-exhaustive_patterns.rs:93 :18
66
78
|
67
79
LL | / union NonEmptyUnion1 {
68
80
LL | | foo: (),
@@ -76,7 +88,7 @@ LL | match_empty!((NonEmptyUnion1 { foo: () }));
76
88
= note: the matched value is of type `NonEmptyUnion1`
77
89
78
90
error[E0004]: non-exhaustive patterns: type `NonEmptyUnion2` is non-empty
79
- --> $DIR/match-empty-exhaustive_patterns.rs:81 :18
91
+ --> $DIR/match-empty-exhaustive_patterns.rs:95 :18
80
92
|
81
93
LL | / union NonEmptyUnion2 {
82
94
LL | | foo: (),
@@ -91,7 +103,7 @@ LL | match_empty!((NonEmptyUnion2 { foo: () }));
91
103
= note: the matched value is of type `NonEmptyUnion2`
92
104
93
105
error[E0004]: non-exhaustive patterns: `Foo(_)` not covered
94
- --> $DIR/match-empty-exhaustive_patterns.rs:83 :18
106
+ --> $DIR/match-empty-exhaustive_patterns.rs:97 :18
95
107
|
96
108
LL | / enum NonEmptyEnum1 {
97
109
LL | | Foo(bool),
@@ -108,7 +120,7 @@ LL | match_empty!(NonEmptyEnum1::Foo(true));
108
120
= note: the matched value is of type `NonEmptyEnum1`
109
121
110
122
error[E0004]: non-exhaustive patterns: `Foo(_)` and `Bar` not covered
111
- --> $DIR/match-empty-exhaustive_patterns.rs:85 :18
123
+ --> $DIR/match-empty-exhaustive_patterns.rs:99 :18
112
124
|
113
125
LL | / enum NonEmptyEnum2 {
114
126
LL | | Foo(bool),
@@ -129,7 +141,7 @@ LL | match_empty!(NonEmptyEnum2::Foo(true));
129
141
= note: the matched value is of type `NonEmptyEnum2`
130
142
131
143
error[E0004]: non-exhaustive patterns: `V1`, `V2`, `V3` and 2 more not covered
132
- --> $DIR/match-empty-exhaustive_patterns.rs:87 :18
144
+ --> $DIR/match-empty-exhaustive_patterns.rs:101 :18
133
145
|
134
146
LL | / enum NonEmptyEnum5 {
135
147
LL | | V1, V2, V3, V4, V5,
@@ -143,7 +155,7 @@ LL | match_empty!(NonEmptyEnum5::V1);
143
155
= note: the matched value is of type `NonEmptyEnum5`
144
156
145
157
error[E0004]: non-exhaustive patterns: `_` not covered
146
- --> $DIR/match-empty-exhaustive_patterns.rs:90 :18
158
+ --> $DIR/match-empty-exhaustive_patterns.rs:104 :18
147
159
|
148
160
LL | match_false!(0u8);
149
161
| ^^^ pattern `_` not covered
@@ -152,7 +164,7 @@ LL | match_false!(0u8);
152
164
= note: the matched value is of type `u8`
153
165
154
166
error[E0004]: non-exhaustive patterns: `NonEmptyStruct(_)` not covered
155
- --> $DIR/match-empty-exhaustive_patterns.rs:92 :18
167
+ --> $DIR/match-empty-exhaustive_patterns.rs:106 :18
156
168
|
157
169
LL | struct NonEmptyStruct(bool);
158
170
| ---------------------------- `NonEmptyStruct` defined here
@@ -164,7 +176,7 @@ LL | match_false!(NonEmptyStruct(true));
164
176
= note: the matched value is of type `NonEmptyStruct`
165
177
166
178
error[E0004]: non-exhaustive patterns: `NonEmptyUnion1 { .. }` not covered
167
- --> $DIR/match-empty-exhaustive_patterns.rs:94 :18
179
+ --> $DIR/match-empty-exhaustive_patterns.rs:108 :18
168
180
|
169
181
LL | / union NonEmptyUnion1 {
170
182
LL | | foo: (),
@@ -178,7 +190,7 @@ LL | match_false!((NonEmptyUnion1 { foo: () }));
178
190
= note: the matched value is of type `NonEmptyUnion1`
179
191
180
192
error[E0004]: non-exhaustive patterns: `NonEmptyUnion2 { .. }` not covered
181
- --> $DIR/match-empty-exhaustive_patterns.rs:96 :18
193
+ --> $DIR/match-empty-exhaustive_patterns.rs:110 :18
182
194
|
183
195
LL | / union NonEmptyUnion2 {
184
196
LL | | foo: (),
@@ -193,7 +205,7 @@ LL | match_false!((NonEmptyUnion2 { foo: () }));
193
205
= note: the matched value is of type `NonEmptyUnion2`
194
206
195
207
error[E0004]: non-exhaustive patterns: `Foo(_)` not covered
196
- --> $DIR/match-empty-exhaustive_patterns.rs:98 :18
208
+ --> $DIR/match-empty-exhaustive_patterns.rs:112 :18
197
209
|
198
210
LL | / enum NonEmptyEnum1 {
199
211
LL | | Foo(bool),
@@ -210,7 +222,7 @@ LL | match_false!(NonEmptyEnum1::Foo(true));
210
222
= note: the matched value is of type `NonEmptyEnum1`
211
223
212
224
error[E0004]: non-exhaustive patterns: `Foo(_)` and `Bar` not covered
213
- --> $DIR/match-empty-exhaustive_patterns.rs:100 :18
225
+ --> $DIR/match-empty-exhaustive_patterns.rs:114 :18
214
226
|
215
227
LL | / enum NonEmptyEnum2 {
216
228
LL | | Foo(bool),
@@ -231,7 +243,7 @@ LL | match_false!(NonEmptyEnum2::Foo(true));
231
243
= note: the matched value is of type `NonEmptyEnum2`
232
244
233
245
error[E0004]: non-exhaustive patterns: `V1`, `V2`, `V3` and 2 more not covered
234
- --> $DIR/match-empty-exhaustive_patterns.rs:102 :18
246
+ --> $DIR/match-empty-exhaustive_patterns.rs:116 :18
235
247
|
236
248
LL | / enum NonEmptyEnum5 {
237
249
LL | | V1, V2, V3, V4, V5,
@@ -244,6 +256,6 @@ LL | match_false!(NonEmptyEnum5::V1);
244
256
= help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms
245
257
= note: the matched value is of type `NonEmptyEnum5`
246
258
247
- error: aborting due to 20 previous errors
259
+ error: aborting due to 22 previous errors
248
260
249
261
For more information about this error, try `rustc --explain E0004`.
0 commit comments