mirror of
https://github.com/rust-lang/rust.git
synced 2024-12-02 19:53:46 +00:00
14 lines
361 B
Plaintext
14 lines
361 B
Plaintext
error: expected one of `.`, `?`, `]`, or an operator, found `:`
|
|
--> $DIR/range-index-instead-of-colon.rs:4:17
|
|
|
|
|
LL | &[1, 2, 3][1:2];
|
|
| ^ expected one of `.`, `?`, `]`, or an operator
|
|
|
|
|
help: you might have meant a range expression
|
|
|
|
|
LL | &[1, 2, 3][1..2];
|
|
| ~~
|
|
|
|
error: aborting due to 1 previous error
|
|
|