Sign in
rust
/
rust
/
refs/heads/try-perf
/
.
/
tests
/
ui
/
move-expr
/
capture-reference.rs
blob: a4c2caee57052ef0847c213e2e1f62b50d3cf933 [
file
] [
edit
]
#![
allow
(
incomplete_features
)]
#![
feature
(
move_expr
)]
fn
main
()
{
let
c
=
{
let
x
=
22
;
||
{
let
y
=
move
(&
x
);
//~^ ERROR `x` does not live long enough
println
!(
"{y:?}"
);
}
};
c
();
}