]> git.lizzy.rs Git - rust.git/blob - tests/ui/consts/const-prop-ice2.rs
suggest fix for attempted integer identifier in patterns
[rust.git] / tests / ui / consts / const-prop-ice2.rs
1 // build-fail
2
3 fn main() {
4     enum Enum { One=1 }
5     let xs=[0;1 as usize];
6     println!("{}", xs[Enum::One as usize]); //~ ERROR this operation will panic at runtime
7 }