fork/rust
git clone https://git.julia.blue/fork/rust
73528e339aa
1.40.0
1warning: any use of this value will cause an error 2 --> $DIR/const-err.rs:10:17 3 | 4LL | const FOO: u8 = [5u8][1]; 5 | ----------------^^^^^^^^- 6 | | 7 | index out of bounds: the len is 1 but the index is 1 8 | 9note: lint level defined here 10 --> $DIR/const-err.rs:4:9 11 | 12LL | #![warn(const_err)] 13 | ^^^^^^^^^ 14 15error[E0080]: erroneous constant used 16 --> $DIR/const-err.rs:14:16 17 | 18LL | black_box((FOO, FOO)); 19 | ^^^ referenced constant has errors 20 21error[E0080]: erroneous constant used 22 --> $DIR/const-err.rs:14:21 23 | 24LL | black_box((FOO, FOO)); 25 | ^^^ referenced constant has errors 26 27error: aborting due to 2 previous errors 28 29For more information about this error, try `rustc --explain E0080`.