mirror of https://github.com/rust-lang/rust
41 lines
1.3 KiB
Plaintext
41 lines
1.3 KiB
Plaintext
error: elided lifetime has a name
|
|
--> $DIR/missing-lifetime-kind.rs:3:32
|
|
|
|
|
LL | fn ampersand<'a>(x: &'a u8) -> &u8 {
|
|
| -- ^ this elided lifetime gets resolved as `'a`
|
|
| |
|
|
| lifetime `'a` declared here
|
|
|
|
|
note: the lint level is defined here
|
|
--> $DIR/missing-lifetime-kind.rs:1:9
|
|
|
|
|
LL | #![deny(elided_named_lifetimes)]
|
|
| ^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
error: elided lifetime has a name
|
|
--> $DIR/missing-lifetime-kind.rs:10:31
|
|
|
|
|
LL | fn brackets<'a>(x: &'a u8) -> Brackets {
|
|
| -- ^^^^^^^^ this elided lifetime gets resolved as `'a`
|
|
| |
|
|
| lifetime `'a` declared here
|
|
|
|
error: elided lifetime has a name
|
|
--> $DIR/missing-lifetime-kind.rs:17:33
|
|
|
|
|
LL | fn comma<'a>(x: &'a u8) -> Comma<u8> {
|
|
| -- ^ this elided lifetime gets resolved as `'a`
|
|
| |
|
|
| lifetime `'a` declared here
|
|
|
|
error: elided lifetime has a name
|
|
--> $DIR/missing-lifetime-kind.rs:22:34
|
|
|
|
|
LL | fn underscore<'a>(x: &'a u8) -> &'_ u8 {
|
|
| -- ^^ this elided lifetime gets resolved as `'a`
|
|
| |
|
|
| lifetime `'a` declared here
|
|
|
|
error: aborting due to 4 previous errors
|
|
|