]>
Commit | Line | Data |
---|---|---|
8faf50e0 | 1 | error[E0312]: lifetime of reference outlives lifetime of borrowed content... |
0731742a | 2 | --> $DIR/issue-10291.rs:3:9 |
8faf50e0 | 3 | | |
532ac7d7 | 4 | LL | x |
8faf50e0 XL |
5 | | ^ |
6 | | | |
dc9dc135 XL |
7 | note: ...the reference is valid for the anonymous lifetime #2 defined on the body at 2:69... |
8 | --> $DIR/issue-10291.rs:2:69 | |
8faf50e0 | 9 | | |
dc9dc135 XL |
10 | LL | drop::<Box<dyn for<'z> FnMut(&'z isize) -> &'z isize>>(Box::new(|z| { |
11 | | _____________________________________________________________________^ | |
532ac7d7 | 12 | LL | | x |
8faf50e0 XL |
13 | LL | | })); |
14 | | |_____^ | |
0731742a XL |
15 | note: ...but the borrowed content is only valid for the lifetime 'x as defined on the function body at 1:9 |
16 | --> $DIR/issue-10291.rs:1:9 | |
8faf50e0 XL |
17 | | |
18 | LL | fn test<'x>(x: &'x isize) { | |
19 | | ^^ | |
20 | ||
21 | error: aborting due to previous error | |
22 | ||
e1599b0c | 23 | For more information about this error, try `rustc --explain E0312`. |