fork/rust

git clone https://git.julia.blue/fork/rust

borsAuto merge of #69444 - pietroalbini:stable-next-final-v2-new, r=pietroalbinif3e1a954d2e

1.41.1
578 B17 linesraw
1error[E0597]: `y` does not live long enough
2  --> $DIR/regions-nested-fns-2.rs:7:25
3   |
4LL |         |z| {
5   |         --- value captured here
6LL |             if false { &y } else { z }
7   |                        -^
8   |                        ||
9   |                        |borrowed value does not live long enough
10   |                        returning this value requires that `y` is borrowed for `'static`
11...
12LL | }
13   | - `y` dropped here while still borrowed
14
15error: aborting due to previous error
16
17For more information about this error, try `rustc --explain E0597`.