rust/src/test/ui/borrowck/regions-escape-bound-fn.stderr
Vadim Petrochenkov fa2d9fc4b9 Update UI tests
2018-02-26 20:24:02 +03:00

13 lines
445 B
Plaintext

error: borrowed data cannot be stored outside of its closure
--> $DIR/regions-escape-bound-fn.rs:18:27
|
LL | let mut x: Option<&isize> = None;
| ----- borrowed data cannot be stored into here...
LL | with_int(|y| x = Some(y));
| --- ^ cannot be stored outside of its closure
| |
| ...because it cannot outlive this closure
error: aborting due to previous error