fork/rust

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

borsAuto merge of #69854 - pietroalbini:stable-next, r=Centrilb8cedc00407

1.42.0
1.1 KiB31 linesraw
1error[E0508]: cannot move out of type `[T]`, a non-copy slice
2  --> $DIR/issue-12567.rs:2:11
3   |
4LL |     match (l1, l2) {
5   |           ^^^^^^^^ cannot move out of here
6...
7LL |         (&[], &[hd, ..]) | (&[hd, ..], &[])
8   |                 -- data moved here
9LL |             => println!("one empty"),
10LL |         (&[hd1, ..], &[hd2, ..])
11   |                        --- ...and here
12   |
13   = note: move occurs because these variables have types that don't implement the `Copy` trait
14
15error[E0508]: cannot move out of type `[T]`, a non-copy slice
16  --> $DIR/issue-12567.rs:2:11
17   |
18LL |     match (l1, l2) {
19   |           ^^^^^^^^ cannot move out of here
20...
21LL |         (&[], &[hd, ..]) | (&[hd, ..], &[])
22   |                 -- data moved here
23LL |             => println!("one empty"),
24LL |         (&[hd1, ..], &[hd2, ..])
25   |            --- ...and here
26   |
27   = note: move occurs because these variables have types that don't implement the `Copy` trait
28
29error: aborting due to 2 previous errors
30
31For more information about this error, try `rustc --explain E0508`.