rust/tests/ui/consts/issue-54348.rs
2024-02-16 20:02:50 +00:00

8 lines
163 B
Rust

//@ build-fail
fn main() {
[1][0u64 as usize];
[1][1.5 as usize]; //~ ERROR operation will panic
[1][1u64 as usize]; //~ ERROR operation will panic
}