mirror of
https://github.com/rust-lang/rust.git
synced 2024-12-02 03:33:59 +00:00
11 lines
395 B
Plaintext
11 lines
395 B
Plaintext
error: lifetime may not live long enough
|
|
--> $DIR/implied-bounds-on-nested-references-plus-variance.rs:8:12
|
|
|
|
|
LL | fn bad<'a, T>(x: &'a T) -> &'static T {
|
|
| -- lifetime `'a` defined here
|
|
LL | let f: fn(_, &'a T) -> &'static T = foo;
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^ type annotation requires that `'a` must outlive `'static`
|
|
|
|
error: aborting due to 1 previous error
|
|
|