fix another test

This commit is contained in:
Ralf Jung 2020-02-15 13:15:15 +01:00
parent 415218fc8d
commit 25870a0b77
2 changed files with 7 additions and 7 deletions

View File

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

View File

@ -1,16 +1,16 @@
error: index out of bounds: the len is 1 but the index is 1
error: this operation will panic at runtime
--> $DIR/issue-54348.rs:5:5
|
LL | [1][1.5 as usize];
| ^^^^^^^^^^^^^^^^^
| ^^^^^^^^^^^^^^^^^ index out of bounds: the len is 1 but the index is 1
|
= note: `#[deny(const_err)]` on by default
= note: `#[deny(panic)]` on by default
error: index out of bounds: the len is 1 but the index is 1
error: this operation will panic at runtime
--> $DIR/issue-54348.rs:6:5
|
LL | [1][1u64 as usize];
| ^^^^^^^^^^^^^^^^^^
| ^^^^^^^^^^^^^^^^^^ index out of bounds: the len is 1 but the index is 1
error: aborting due to 2 previous errors