]> git.lizzy.rs Git - rust.git/blob - src/test/ui/not-copy-closure.stderr
Rollup merge of #53317 - estebank:abolish-ice, r=oli-obk
[rust.git] / src / test / ui / not-copy-closure.stderr
1 error[E0382]: use of moved value: `hello`
2   --> $DIR/not-copy-closure.rs:20:9
3    |
4 LL |     let b = hello;
5    |         - value moved here
6 LL |     let c = hello; //~ ERROR use of moved value: `hello` [E0382]
7    |         ^ value used here after move
8    |
9 note: closure cannot be invoked more than once because it moves the variable `a` out of its environment
10   --> $DIR/not-copy-closure.rs:16:9
11    |
12 LL |         a += 1;
13    |         ^
14
15 error: aborting due to previous error
16
17 For more information about this error, try `rustc --explain E0382`.