2019-01-12 08:55:23 -06:00
|
|
|
error: lifetime may not live long enough
|
|
|
|
--> $DIR/regions-free-region-ordering-caller.rs:11:12
|
|
|
|
|
|
|
|
|
LL | fn call2<'a, 'b>(a: &'a usize, b: &'b usize) {
|
|
|
|
| -- -- lifetime `'b` defined here
|
|
|
|
| |
|
|
|
|
| lifetime `'a` defined here
|
2019-03-17 04:52:07 -05:00
|
|
|
LL | let z: Option<&'b &'a usize> = None;
|
2019-01-12 08:55:23 -06:00
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^ type annotation requires that `'a` must outlive `'b`
|
|
|
|
|
2018-11-28 15:05:36 -06:00
|
|
|
help: the following changes may resolve your lifetime errors
|
|
|
|
|
|
|
|
|
= help: add bound `'a: 'b`
|
|
|
|
|
2019-01-12 08:55:23 -06:00
|
|
|
error: lifetime may not live long enough
|
|
|
|
--> $DIR/regions-free-region-ordering-caller.rs:17:12
|
|
|
|
|
|
|
|
|
LL | fn call3<'a, 'b>(a: &'a usize, b: &'b usize) {
|
|
|
|
| -- -- lifetime `'b` defined here
|
|
|
|
| |
|
|
|
|
| lifetime `'a` defined here
|
|
|
|
LL | let y: Paramd<'a> = Paramd { x: a };
|
2019-03-17 04:52:07 -05:00
|
|
|
LL | let z: Option<&'b Paramd<'a>> = None;
|
2019-01-12 08:55:23 -06:00
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^ type annotation requires that `'a` must outlive `'b`
|
|
|
|
|
2018-11-28 15:05:36 -06:00
|
|
|
help: the following changes may resolve your lifetime errors
|
|
|
|
|
|
|
|
|
= help: add bound `'a: 'b`
|
|
|
|
|
2019-01-12 08:55:23 -06:00
|
|
|
error: lifetime may not live long enough
|
|
|
|
--> $DIR/regions-free-region-ordering-caller.rs:22:12
|
|
|
|
|
|
|
|
|
LL | fn call4<'a, 'b>(a: &'a usize, b: &'b usize) {
|
|
|
|
| -- -- lifetime `'b` defined here
|
|
|
|
| |
|
|
|
|
| lifetime `'a` defined here
|
2019-03-17 04:52:07 -05:00
|
|
|
LL | let z: Option<&'a &'b usize> = None;
|
2019-01-12 08:55:23 -06:00
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^ type annotation requires that `'b` must outlive `'a`
|
|
|
|
|
2018-11-28 15:05:36 -06:00
|
|
|
help: the following changes may resolve your lifetime errors
|
|
|
|
|
|
|
|
|
= help: add bound `'b: 'a`
|
|
|
|
|
2019-01-12 08:55:23 -06:00
|
|
|
error: aborting due to 3 previous errors
|
|
|
|
|