]>
Commit | Line | Data |
---|---|---|
9fa01778 XL |
1 | error: lifetime may not live long enough |
2 | --> $DIR/regions-free-region-ordering-caller.rs:11:12 | |
3 | | | |
4 | LL | fn call2<'a, 'b>(a: &'a usize, b: &'b usize) { | |
5 | | -- -- lifetime `'b` defined here | |
6 | | | | |
7 | | lifetime `'a` defined here | |
532ac7d7 | 8 | LL | let z: Option<&'b &'a usize> = None; |
9fa01778 | 9 | | ^^^^^^^^^^^^^^^^^^^^^ type annotation requires that `'a` must outlive `'b` |
60c5eb7d XL |
10 | | |
11 | = help: consider adding the following bound: `'a: 'b` | |
9fa01778 XL |
12 | |
13 | error: lifetime may not live long enough | |
14 | --> $DIR/regions-free-region-ordering-caller.rs:17:12 | |
15 | | | |
16 | LL | fn call3<'a, 'b>(a: &'a usize, b: &'b usize) { | |
17 | | -- -- lifetime `'b` defined here | |
18 | | | | |
19 | | lifetime `'a` defined here | |
20 | LL | let y: Paramd<'a> = Paramd { x: a }; | |
532ac7d7 | 21 | LL | let z: Option<&'b Paramd<'a>> = None; |
9fa01778 | 22 | | ^^^^^^^^^^^^^^^^^^^^^^ type annotation requires that `'a` must outlive `'b` |
60c5eb7d XL |
23 | | |
24 | = help: consider adding the following bound: `'a: 'b` | |
9fa01778 XL |
25 | |
26 | error: lifetime may not live long enough | |
27 | --> $DIR/regions-free-region-ordering-caller.rs:22:12 | |
28 | | | |
29 | LL | fn call4<'a, 'b>(a: &'a usize, b: &'b usize) { | |
30 | | -- -- lifetime `'b` defined here | |
31 | | | | |
32 | | lifetime `'a` defined here | |
532ac7d7 | 33 | LL | let z: Option<&'a &'b usize> = None; |
9fa01778 | 34 | | ^^^^^^^^^^^^^^^^^^^^^ type annotation requires that `'b` must outlive `'a` |
60c5eb7d XL |
35 | | |
36 | = help: consider adding the following bound: `'b: 'a` | |
9fa01778 XL |
37 | |
38 | error: aborting due to 3 previous errors | |
39 |