Skip to content

Commit

Permalink
Fix ci test issue-94239.rs
Browse files Browse the repository at this point in the history
  • Loading branch information
light4 committed Feb 25, 2022
1 parent 5b58c6f commit b0c4db3
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/test/ui/issues/issue-94239.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
pub const fn test_match_range(len: usize) -> usize {
pub const fn test_match_range(len: u64) -> u64 {
match len {
10000000000000000000..=99999999999999999999 => 0, //~ ERROR literal out of range for `usize`
10000000000000000000..=99999999999999999999 => 0, //~ ERROR literal out of range for `u64`
_ => unreachable!(),
}
}
Expand Down
4 changes: 2 additions & 2 deletions src/test/ui/issues/issue-94239.stderr
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
error: literal out of range for `usize`
error: literal out of range for `u64`
--> $DIR/issue-94239.rs:3:32
|
LL | 10000000000000000000..=99999999999999999999 => 0,
| ^^^^^^^^^^^^^^^^^^^^
|
= note: `#[deny(overflowing_literals)]` on by default
= note: the literal `99999999999999999999` does not fit into the type `usize` whose range is `0..=18446744073709551615`
= note: the literal `99999999999999999999` does not fit into the type `u64` whose range is `0..=18446744073709551615`

error: aborting due to previous error

0 comments on commit b0c4db3

Please sign in to comment.