]>
Commit | Line | Data |
---|---|---|
b7449926 | 1 | error[E0597]: `c` does not live long enough |
48663c56 | 2 | --> $DIR/method-call.rs:36:34 |
b7449926 | 3 | | |
532ac7d7 | 4 | LL | a.method::<&'static u32>(b, &c); |
0bf4aa26 XL |
5 | | -----------------------------^^- |
6 | | | | | |
7 | | | borrowed value does not live long enough | |
8 | | argument requires that `c` is borrowed for `'static` | |
b7449926 XL |
9 | LL | } |
10 | | - `c` dropped here while still borrowed | |
b7449926 XL |
11 | |
12 | error[E0597]: `c` does not live long enough | |
48663c56 | 13 | --> $DIR/method-call.rs:43:29 |
b7449926 | 14 | | |
0bf4aa26 XL |
15 | LL | fn annot_reference_named_lifetime<'a>(_d: &'a u32) { |
16 | | -- lifetime `'a` defined here | |
17 | ... | |
532ac7d7 | 18 | LL | a.method::<&'a u32>(b, &c); |
0bf4aa26 XL |
19 | | ------------------------^^- |
20 | | | | | |
21 | | | borrowed value does not live long enough | |
22 | | argument requires that `c` is borrowed for `'a` | |
b7449926 XL |
23 | LL | } |
24 | | - `c` dropped here while still borrowed | |
b7449926 XL |
25 | |
26 | error[E0597]: `c` does not live long enough | |
48663c56 | 27 | --> $DIR/method-call.rs:57:33 |
b7449926 | 28 | | |
0bf4aa26 XL |
29 | LL | fn annot_reference_named_lifetime_in_closure<'a>(_: &'a u32) { |
30 | | -- lifetime `'a` defined here | |
31 | ... | |
532ac7d7 | 32 | LL | a.method::<&'a u32>(b, &c); |
0bf4aa26 XL |
33 | | ------------------------^^- |
34 | | | | | |
35 | | | borrowed value does not live long enough | |
36 | | argument requires that `c` is borrowed for `'a` | |
f2b60f7d FG |
37 | LL | }; |
38 | | - `c` dropped here while still borrowed | |
b7449926 XL |
39 | |
40 | error: aborting due to 3 previous errors | |
41 | ||
42 | For more information about this error, try `rustc --explain E0597`. |