summary refs log tree commit diff
path: root/src/test/ui/span/borrowck-ref-into-rvalue.nll.stderr
blob: 171bb3dda66646302a787f33c4faf626e060f796 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
error[E0597]: borrowed value does not live long enough
  --> $DIR/borrowck-ref-into-rvalue.rs:13:11
   |
LL |     match Some("Hello".to_string()) {
   |           ^^^^^^^^^^^^^^^^^^^^^^^^^ temporary value does not live long enough
...
LL |     }
   |     - temporary value only lives until here
LL |     println!("{}", *msg);
   |                    ---- borrow later used here

error: aborting due to previous error

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