1 error[E0505]: cannot move out of `x1` because it is borrowed
2 --> $DIR/borrowck-multiple-captures.rs:12:19
5 | --- borrow of `x1` occurs here
7 LL | thread::spawn(move|| {
8 | ^^^^^^ move out of `x1` occurs here
11 | -- move occurs due to use in closure
14 | ---- borrow later used here
16 error[E0505]: cannot move out of `x2` because it is borrowed
17 --> $DIR/borrowck-multiple-captures.rs:12:19
20 | --- borrow of `x2` occurs here
21 LL | thread::spawn(move|| {
22 | ^^^^^^ move out of `x2` occurs here
25 | -- move occurs due to use in closure
28 | ---- borrow later used here
30 error[E0382]: use of moved value: `x1`
31 --> $DIR/borrowck-multiple-captures.rs:27:19
33 LL | let x1: Box<_> = Box::new(1);
34 | -- move occurs because `x1` has type `Box<i32>`, which does not implement the `Copy` trait
38 LL | thread::spawn(move|| {
39 | ^^^^^^ value used here after move
42 | -- use occurs due to use in closure
44 help: consider cloning the value if the performance cost is acceptable
46 LL | drop(x1.clone());
49 error[E0382]: use of moved value: `x2`
50 --> $DIR/borrowck-multiple-captures.rs:27:19
52 LL | let x2: Box<_> = Box::new(2);
53 | -- move occurs because `x2` has type `Box<i32>`, which does not implement the `Copy` trait
56 LL | thread::spawn(move|| {
57 | ^^^^^^ value used here after move
60 | -- use occurs due to use in closure
62 help: consider cloning the value if the performance cost is acceptable
64 LL | drop(x2.clone());
67 error[E0382]: use of moved value: `x`
68 --> $DIR/borrowck-multiple-captures.rs:41:14
73 | ^ value used here after move
75 = note: move occurs because `x` has type `Box<i32>`, which does not implement the `Copy` trait
77 error[E0505]: cannot move out of `x` because it is borrowed
78 --> $DIR/borrowck-multiple-captures.rs:38:19
81 | -- borrow of `x` occurs here
82 LL | thread::spawn(move|| {
83 | ^^^^^^ move out of `x` occurs here
86 | - move occurs due to use in closure
89 | --- borrow later used here
91 error[E0382]: use of moved value: `x`
92 --> $DIR/borrowck-multiple-captures.rs:52:14
97 | ^ value used here after move
99 = note: move occurs because `x` has type `Box<i32>`, which does not implement the `Copy` trait
101 error[E0382]: use of moved value: `x`
102 --> $DIR/borrowck-multiple-captures.rs:49:19
104 LL | let x: Box<_> = Box::new(1);
105 | - move occurs because `x` has type `Box<i32>`, which does not implement the `Copy` trait
108 LL | thread::spawn(move|| {
109 | ^^^^^^ value used here after move
112 | - use occurs due to use in closure
114 help: consider cloning the value if the performance cost is acceptable
116 LL | drop(x.clone());
119 error: aborting due to 8 previous errors
121 Some errors have detailed explanations: E0382, E0505.
122 For more information about an error, try `rustc --explain E0382`.