blob: 3fedb2884bc58c8cd3c52f469c3f19f3cdf5d224 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
error: `x` does not live long enough
--> $DIR/issue-11925.rs:18:36
|
18 | let f = to_fn_once(move|| &x);
| ^
| |
| does not live long enough
| borrowed value only lives until here
...
23 | }
| - borrowed value needs to live until here
error: aborting due to previous error
|