You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: tests/ui/pattern/usefulness/integer-ranges/pointer-sized-int.deny.stderr
+25-26Lines changed: 25 additions & 26 deletions
Original file line number
Diff line number
Diff line change
@@ -9,7 +9,7 @@ LL | match 0usize {
9
9
= help: add `#![feature(precise_pointer_size_matching)]` to the crate attributes to enable precise `usize` matching
10
10
help: ensure that all possible cases are being handled by adding a match arm with a wildcard pattern or an explicit pattern as shown
11
11
|
12
-
LL ~ 0..=usize::MAX => {},
12
+
LL ~ 0..=usize::MAX => {},
13
13
LL + usize::MAX.. => todo!()
14
14
|
15
15
@@ -24,12 +24,12 @@ LL | match 0isize {
24
24
= help: add `#![feature(precise_pointer_size_matching)]` to the crate attributes to enable precise `isize` matching
25
25
help: ensure that all possible cases are being handled by adding a match arm with a wildcard pattern, a match arm with multiple or-patterns as shown, or multiple match arms
26
26
|
27
-
LL ~ isize::MIN..=isize::MAX => {},
27
+
LL ~ isize::MIN..=isize::MAX => {},
28
28
LL + ..isize::MIN | isize::MAX.. => todo!()
29
29
|
30
30
31
31
error[E0004]: non-exhaustive patterns: `usize::MAX..` not covered
| ^^^^^^ patterns `..isize::MIN` and `isize::MAX..` not covered
134
134
|
135
-
= note: the matched value is of type `(isize, bool)`
135
+
= note: the matched value is of type `isize`
136
136
= note: `isize` does not have fixed minimum and maximum values, so half-open ranges are necessary to match exhaustively
137
137
= help: add `#![feature(precise_pointer_size_matching)]` to the crate attributes to enable precise `isize` matching
138
138
help: ensure that all possible cases are being handled by adding a match arm with a wildcard pattern, a match arm with multiple or-patterns as shown, or multiple match arms
error[E0004]: non-exhaustive patterns: `..isize::MIN` and `isize::MAX..` not covered
144
-
--> $DIR/pointer-sized-int.rs:47:11
143
+
error[E0004]: non-exhaustive patterns: `(..isize::MIN, _)` and `(isize::MAX.., _)` not covered
144
+
--> $DIR/pointer-sized-int.rs:48:9
145
145
|
146
-
LL | match 0isize {
147
-
| ^^^^^^ patterns `..isize::MIN` and `isize::MAX..` not covered
146
+
LL | (0isize, true),
147
+
| ^^^^^^^^^^^^^^ patterns `(..isize::MIN, _)` and `(isize::MAX.., _)` not covered
148
148
|
149
-
= note: the matched value is of type `isize`
149
+
= note: the matched value is of type `(isize, bool)`
150
150
= note: `isize` does not have fixed minimum and maximum values, so half-open ranges are necessary to match exhaustively
151
151
= help: add `#![feature(precise_pointer_size_matching)]` to the crate attributes to enable precise `isize` matching
152
152
help: ensure that all possible cases are being handled by adding a match arm with a wildcard pattern, a match arm with multiple or-patterns as shown, or multiple match arms
0 commit comments