2024-04-04 12:54:56 -04:00
error[E0106]: missing lifetime specifier
2024-07-12 06:12:24 -04:00
--> $DIR/bad-lifetimes.rs:1:39
2024-04-04 12:54:56 -04:00
|
2024-06-05 16:18:52 -04:00
LL | fn no_elided_lt() -> impl Sized + use<'_> {}
| ^^ expected named lifetime parameter
2024-04-04 12:54:56 -04:00
|
= help: this function's return type contains a borrowed value, but there is no value for it to be borrowed from
help: consider using the `'static` lifetime, but this is uncommon unless you're returning a borrowed value from a `const` or a `static`, or if you will only have owned values
|
2024-06-05 16:18:52 -04:00
LL | fn no_elided_lt() -> impl Sized + use<'static> {}
| ~~~~~~~
2024-04-04 12:54:56 -04:00
error[E0261]: use of undeclared lifetime name `'missing`
2024-07-12 06:12:24 -04:00
--> $DIR/bad-lifetimes.rs:8:37
2024-04-04 12:54:56 -04:00
|
2024-06-05 16:18:52 -04:00
LL | fn missing_lt() -> impl Sized + use<'missing> {}
| - ^^^^^^^^ undeclared lifetime
2024-04-04 12:54:56 -04:00
| |
| help: consider introducing lifetime `'missing` here: `<'missing>`
error: expected lifetime parameter in `use<...>` precise captures list, found `'_`
2024-07-12 06:12:24 -04:00
--> $DIR/bad-lifetimes.rs:1:39
2024-04-04 12:54:56 -04:00
|
2024-06-05 16:18:52 -04:00
LL | fn no_elided_lt() -> impl Sized + use<'_> {}
| ^^
2024-04-04 12:54:56 -04:00
error: expected lifetime parameter in `use<...>` precise captures list, found `'static`
2024-07-12 06:12:24 -04:00
--> $DIR/bad-lifetimes.rs:5:36
2024-04-04 12:54:56 -04:00
|
2024-06-05 16:18:52 -04:00
LL | fn static_lt() -> impl Sized + use<'static> {}
| ^^^^^^^
2024-04-04 12:54:56 -04:00
2024-06-16 22:07:23 -04:00
error: aborting due to 4 previous errors
2024-04-04 12:54:56 -04:00
Some errors have detailed explanations: E0106, E0261.
For more information about an error, try `rustc --explain E0106`.