2019-05-02 17:34:15 -05:00
|
|
|
error[E0597]: `z` does not live long enough
|
|
|
|
--> $DIR/issue-46471-1.rs:4:9
|
2017-12-10 14:36:42 -06:00
|
|
|
|
|
2023-01-14 21:06:44 -06:00
|
|
|
LL | let mut z = 0;
|
|
|
|
| ----- binding `z` declared here
|
2018-08-25 06:13:28 -05:00
|
|
|
LL | &mut z
|
2023-01-14 21:06:44 -06:00
|
|
|
| ^^^^^^ borrowed value does not live long enough
|
2018-08-25 06:13:28 -05:00
|
|
|
LL | };
|
|
|
|
| - `z` dropped here while still borrowed
|
2017-12-10 14:36:42 -06:00
|
|
|
|
2019-05-02 17:34:15 -05:00
|
|
|
error: aborting due to previous error
|
2017-12-10 14:36:42 -06:00
|
|
|
|
2018-03-03 08:59:40 -06:00
|
|
|
For more information about this error, try `rustc --explain E0597`.
|