2019-12-02 11:54:42 -06:00
|
|
|
error: lifetime may not live long enough
|
2021-08-03 11:59:52 -05:00
|
|
|
--> $DIR/error-handling.rs:22:16
|
2019-12-02 11:54:42 -06:00
|
|
|
|
|
|
|
|
LL | fn foo<'a, 'b, 'c>(x: &'static i32, mut y: &'a i32) -> E<'b, 'c> {
|
2020-03-29 18:28:27 -05:00
|
|
|
| -- -- lifetime `'b` defined here
|
2019-12-02 11:54:42 -06:00
|
|
|
| |
|
|
|
|
| lifetime `'a` defined here
|
2020-03-29 18:28:27 -05:00
|
|
|
...
|
|
|
|
LL | let _: &'b i32 = *u.0;
|
|
|
|
| ^^^^^^^ type annotation requires that `'a` must outlive `'b`
|
2019-12-02 11:54:42 -06:00
|
|
|
|
|
|
|
|
= help: consider adding the following bound: `'a: 'b`
|
|
|
|
|
|
|
|
error: aborting due to previous error
|
|
|
|
|