]> git.lizzy.rs Git - rust.git/blob - tests/ui/nll/user-annotations/method-ufcs-inherent-3.stderr
Auto merge of #105716 - chriswailes:ndk-update-redux, r=pietroalbini
[rust.git] / tests / ui / nll / user-annotations / method-ufcs-inherent-3.stderr
1 error[E0597]: `v` does not live long enough
2   --> $DIR/method-ufcs-inherent-3.rs:14:26
3    |
4 LL | fn foo<'a>() {
5    |        -- lifetime `'a` defined here
6 LL |     let v = 22;
7 LL |     let x = <A<'a>>::new(&v, 22);
8    |             -------------^^-----
9    |             |            |
10    |             |            borrowed value does not live long enough
11    |             argument requires that `v` is borrowed for `'a`
12 LL |
13 LL | }
14    | - `v` dropped here while still borrowed
15
16 error: aborting due to previous error
17
18 For more information about this error, try `rustc --explain E0597`.