fork/rust

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

borsAuto merge of #66089 - Mark-Simulacrum:stable-next, r=Mark-Simulacrum4560ea788cb

1.39.0
604 B17 linesraw
1error[E0382]: use of moved value: `tick`
2  --> $DIR/unboxed-closures-infer-fnonce-move-call-twice.rs:10:5
3   |
4LL |     tick();
5   |     ---- value moved here
6LL |     tick();
7   |     ^^^^ value used here after move
8   |
9note: closure cannot be invoked more than once because it moves the variable `counter` out of its environment
10  --> $DIR/unboxed-closures-infer-fnonce-move-call-twice.rs:8:34
11   |
12LL |     let tick = move || mem::drop(counter);
13   |                                  ^^^^^^^
14
15error: aborting due to previous error
16
17For more information about this error, try `rustc --explain E0382`.