fork/rust

git clone https://git.julia.blue/fork/rust

borsAuto merge of #66089 - Mark-Simulacrum:stable-next, r=Mark-Simulacrum4560ea788cb

1.39.0
490 B18 linesraw
1error: index out of bounds: the len is 3 but the index is 4
2  --> $DIR/array-literal-index-oob.rs:2:7
3   |
4LL |     &{[1, 2, 3][4]};
5   |       ^^^^^^^^^^^^
6   |
7   = note: `#[deny(const_err)]` on by default
8
9error: reaching this expression at runtime will panic or abort
10  --> $DIR/array-literal-index-oob.rs:2:7
11   |
12LL |     &{[1, 2, 3][4]};
13   |     --^^^^^^^^^^^^-
14   |       |
15   |       index out of bounds: the len is 3 but the index is 4
16
17error: aborting due to 2 previous errors
18