summary refs log tree commit diff
path: root/src/test/ui/nll/borrowed-universal-error.stderr
blob: 94d9bb36fa42826aaf961fef64fd141e84f58389 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
error[E0597]: borrowed value does not live long enough
  --> $DIR/borrowed-universal-error.rs:20:12
   |
LL |     gimme(&(v,))
   |            ^^^^ temporary value does not live long enough
LL |     //~^ ERROR borrowed value does not live long enough [E0597]
LL | }
   | - temporary value only lives until here
   |
note: borrowed value must be valid for the lifetime 'a as defined on the function body at 18:1...
  --> $DIR/borrowed-universal-error.rs:18:1
   |
LL | fn foo<'a>(x: &'a (u32,)) -> &'a u32 {
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

error: aborting due to previous error

For more information about this error, try `rustc --explain E0597`.