1 error[E0507]: cannot move out of `*a` which is behind a shared reference
2 --> $DIR/move-errors.rs:6:13
5 | ^^ move occurs because `*a` has type `A`, which does not implement the `Copy` trait
7 help: consider removing the dereference here
13 error[E0508]: cannot move out of type `[A; 1]`, a non-copy array
14 --> $DIR/move-errors.rs:12:13
19 | cannot move out of here
20 | move occurs because `a[_]` has type `A`, which does not implement the `Copy` trait
22 help: consider borrowing here
27 error[E0507]: cannot move out of `**r` which is behind a shared reference
28 --> $DIR/move-errors.rs:19:13
31 | ^^^ move occurs because `**r` has type `A`, which does not implement the `Copy` trait
33 help: consider removing the dereference here
39 error[E0507]: cannot move out of an `Rc`
40 --> $DIR/move-errors.rs:27:13
43 | ^^ move occurs because value has type `A`, which does not implement the `Copy` trait
45 help: consider removing the dereference here
51 error[E0508]: cannot move out of type `[A; 1]`, a non-copy array
52 --> $DIR/move-errors.rs:32:13
54 LL | let a = [A("".to_string())][0];
55 | ^^^^^^^^^^^^^^^^^^^^^^
57 | cannot move out of here
58 | move occurs because value has type `A`, which does not implement the `Copy` trait
60 help: consider borrowing here
62 LL | let a = &[A("".to_string())][0];
65 error[E0507]: cannot move out of `a` which is behind a shared reference
66 --> $DIR/move-errors.rs:38:16
72 | move occurs because `s` has type `String`, which does not implement the `Copy` trait
74 help: consider removing the dereference here
80 error[E0509]: cannot move out of type `D`, which implements the `Drop` trait
81 --> $DIR/move-errors.rs:44:19
84 | - ^ cannot move out of here
87 | move occurs because `s` has type `String`, which does not implement the `Copy` trait
89 help: consider borrowing the pattern binding
91 LL | let C(D(ref s)) = c;
94 error[E0507]: cannot move out of `*a` which is behind a shared reference
95 --> $DIR/move-errors.rs:51:9
98 | ^^ move occurs because `*a` has type `A`, which does not implement the `Copy` trait
100 error[E0508]: cannot move out of type `[B; 1]`, a non-copy array
101 --> $DIR/move-errors.rs:74:11
104 | ^^^^ cannot move out of here
111 = note: move occurs because these variables have types that don't implement the `Copy` trait
112 help: consider borrowing here
117 error[E0509]: cannot move out of type `D`, which implements the `Drop` trait
118 --> $DIR/move-errors.rs:83:11
121 | ^ cannot move out of here
123 LL | B::U(D(s)) => (),
127 | move occurs because `s` has type `String`, which does not implement the `Copy` trait
129 help: consider borrowing the pattern binding
131 LL | B::U(D(ref s)) => (),
134 error[E0509]: cannot move out of type `D`, which implements the `Drop` trait
135 --> $DIR/move-errors.rs:92:11
138 | ^ cannot move out of here
140 LL | (D(s), &t) => (),
144 | move occurs because `s` has type `String`, which does not implement the `Copy` trait
146 help: consider borrowing the pattern binding
148 LL | (D(ref s), &t) => (),
151 error[E0507]: cannot move out of `*x.1` which is behind a shared reference
152 --> $DIR/move-errors.rs:92:11
157 LL | (D(s), &t) => (),
161 | move occurs because `t` has type `String`, which does not implement the `Copy` trait
163 help: consider borrowing the pattern binding
165 LL | (D(s), &ref t) => (),
168 error[E0509]: cannot move out of type `F`, which implements the `Drop` trait
169 --> $DIR/move-errors.rs:102:11
172 | ^ cannot move out of here
174 LL | F(s, mut t) => (),
175 | - ----- ...and here
179 = note: move occurs because these variables have types that don't implement the `Copy` trait
180 help: consider borrowing the pattern binding
182 LL | F(ref s, mut t) => (),
184 help: consider borrowing the pattern binding
186 LL | F(s, ref mut t) => (),
189 error[E0507]: cannot move out of `x` as enum variant `Err` which is behind a shared reference
190 --> $DIR/move-errors.rs:110:11
195 LL | Ok(s) | Err(s) => (),
199 | move occurs because `s` has type `String`, which does not implement the `Copy` trait
201 help: consider removing the dereference here
207 error: aborting due to 14 previous errors
209 Some errors have detailed explanations: E0507, E0508, E0509.
210 For more information about an error, try `rustc --explain E0507`.