Skip to content

Commit 25870a0

Browse files
committed
fix another test
1 parent 415218f commit 25870a0

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

src/test/ui/issues/issue-54348.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,6 @@
22

33
fn main() {
44
[1][0u64 as usize];
5-
[1][1.5 as usize]; //~ ERROR index out of bounds
6-
[1][1u64 as usize]; //~ ERROR index out of bounds
5+
[1][1.5 as usize]; //~ ERROR operation will panic
6+
[1][1u64 as usize]; //~ ERROR operation will panic
77
}

src/test/ui/issues/issue-54348.stderr

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
1-
error: index out of bounds: the len is 1 but the index is 1
1+
error: this operation will panic at runtime
22
--> $DIR/issue-54348.rs:5:5
33
|
44
LL | [1][1.5 as usize];
5-
| ^^^^^^^^^^^^^^^^^
5+
| ^^^^^^^^^^^^^^^^^ index out of bounds: the len is 1 but the index is 1
66
|
7-
= note: `#[deny(const_err)]` on by default
7+
= note: `#[deny(panic)]` on by default
88

9-
error: index out of bounds: the len is 1 but the index is 1
9+
error: this operation will panic at runtime
1010
--> $DIR/issue-54348.rs:6:5
1111
|
1212
LL | [1][1u64 as usize];
13-
| ^^^^^^^^^^^^^^^^^^
13+
| ^^^^^^^^^^^^^^^^^^ index out of bounds: the len is 1 but the index is 1
1414

1515
error: aborting due to 2 previous errors
1616

0 commit comments

Comments
 (0)