e771a4f989
Do not trigger on correct type ascription expressions with trailing operators and _do_ trigger on likely path typos where a turbofish is used. On likely path typos, remove note explaining type ascription.
24 lines
864 B
Plaintext
24 lines
864 B
Plaintext
error: expected identifier, found keyword `loop`
|
|
--> $DIR/lifetime_starts_expressions.rs:6:26
|
|
|
|
|
LL | loop { break 'label: loop { break 'label 42; }; }
|
|
| ^^^^ expected identifier, found keyword
|
|
|
|
|
help: you can escape reserved keywords to use them as identifiers
|
|
|
|
|
LL | loop { break 'label: r#loop { break 'label 42; }; }
|
|
| ^^^^^^
|
|
|
|
error: expected type, found keyword `loop`
|
|
--> $DIR/lifetime_starts_expressions.rs:6:26
|
|
|
|
|
LL | loop { break 'label: loop { break 'label 42; }; }
|
|
| - ^^^^ expected type
|
|
| |
|
|
| help: maybe write a path separator here: `::`
|
|
|
|
|
= note: `#![feature(type_ascription)]` lets you annotate an expression with a type: `<expr>: <type>`
|
|
|
|
error: aborting due to 2 previous errors
|
|
|