|
1 | 1 | error[E0382]: use of moved value
|
2 |
| - --> $DIR/borrowck-move-and-move.rs:13:13 |
| 2 | + --> $DIR/borrowck-move-and-move.rs:13:9 |
3 | 3 | |
|
4 | 4 | LL | let a @ b = U;
|
5 |
| - | ----^ - move occurs because value has type `U`, which does not implement the `Copy` trait |
| 5 | + | ^^^^- - move occurs because value has type `U`, which does not implement the `Copy` trait |
6 | 6 | | | |
|
7 |
| - | | value used here after move |
8 |
| - | value moved here |
| 7 | + | | value moved here |
| 8 | + | value used here after move |
9 | 9 |
|
10 |
| -error[E0382]: use of moved value |
11 |
| - --> $DIR/borrowck-move-and-move.rs:15:17 |
| 10 | +error[E0382]: use of partially moved value |
| 11 | + --> $DIR/borrowck-move-and-move.rs:15:9 |
12 | 12 | |
|
13 | 13 | LL | let a @ (b, c) = (U, U);
|
14 |
| - | --------^- ------ move occurs because value has type `(U, U)`, which does not implement the `Copy` trait |
15 |
| - | | | |
16 |
| - | | value used here after move |
17 |
| - | value moved here |
| 14 | + | ^^^^^-^^^^ |
| 15 | + | | | |
| 16 | + | | value partially moved here |
| 17 | + | value used here after partial move |
| 18 | + | |
| 19 | + = note: partial move occurs because value has type `U`, which does not implement the `Copy` trait |
18 | 20 |
|
19 |
| -error[E0382]: use of moved value |
20 |
| - --> $DIR/borrowck-move-and-move.rs:17:17 |
| 21 | +error[E0382]: use of partially moved value |
| 22 | + --> $DIR/borrowck-move-and-move.rs:17:9 |
21 | 23 | |
|
22 | 24 | LL | let a @ (b, c) = (u(), u());
|
23 |
| - | --------^- ---------- move occurs because value has type `(U, U)`, which does not implement the `Copy` trait |
24 |
| - | | | |
25 |
| - | | value used here after move |
26 |
| - | value moved here |
| 25 | + | ^^^^^-^^^^ |
| 26 | + | | | |
| 27 | + | | value partially moved here |
| 28 | + | value used here after partial move |
| 29 | + | |
| 30 | + = note: partial move occurs because value has type `U`, which does not implement the `Copy` trait |
27 | 31 |
|
28 |
| -error[E0382]: use of moved value |
29 |
| - --> $DIR/borrowck-move-and-move.rs:20:16 |
| 32 | +error[E0382]: use of partially moved value |
| 33 | + --> $DIR/borrowck-move-and-move.rs:20:9 |
30 | 34 | |
|
31 |
| -LL | match Ok(U) { |
32 |
| - | ----- move occurs because value has type `std::result::Result<U, U>`, which does not implement the `Copy` trait |
33 | 35 | LL | a @ Ok(b) | a @ Err(b) => {}
|
34 |
| - | -------^- |
| 36 | + | ^^^^^^^-^ |
35 | 37 | | | |
|
36 |
| - | | value used here after move |
37 |
| - | value moved here |
| 38 | + | | value partially moved here |
| 39 | + | value used here after partial move |
| 40 | + | |
| 41 | + = note: partial move occurs because value has type `U`, which does not implement the `Copy` trait |
| 42 | +help: borrow this field in the pattern to avoid moving the value |
| 43 | + | |
| 44 | +LL | a @ Ok(ref b) | a @ Err(b) => {} |
| 45 | + | ^^^ |
38 | 46 |
|
39 |
| -error[E0382]: use of moved value |
40 |
| - --> $DIR/borrowck-move-and-move.rs:20:29 |
| 47 | +error[E0382]: use of partially moved value |
| 48 | + --> $DIR/borrowck-move-and-move.rs:20:21 |
41 | 49 | |
|
42 |
| -LL | match Ok(U) { |
43 |
| - | ----- move occurs because value has type `std::result::Result<U, U>`, which does not implement the `Copy` trait |
44 | 50 | LL | a @ Ok(b) | a @ Err(b) => {}
|
45 |
| - | --------^- |
| 51 | + | ^^^^^^^^-^ |
46 | 52 | | | |
|
47 |
| - | | value used here after move |
48 |
| - | value moved here |
| 53 | + | | value partially moved here |
| 54 | + | value used here after partial move |
| 55 | + | |
| 56 | + = note: partial move occurs because value has type `U`, which does not implement the `Copy` trait |
| 57 | +help: borrow this field in the pattern to avoid moving the value |
| 58 | + | |
| 59 | +LL | a @ Ok(b) | a @ Err(ref b) => {} |
| 60 | + | ^^^ |
49 | 61 |
|
50 |
| -error[E0382]: use of moved value |
51 |
| - --> $DIR/borrowck-move-and-move.rs:27:22 |
| 62 | +error[E0382]: use of partially moved value |
| 63 | + --> $DIR/borrowck-move-and-move.rs:27:9 |
52 | 64 | |
|
53 |
| -LL | match [u(), u(), u(), u()] { |
54 |
| - | -------------------- move occurs because value has type `[U; 4]`, which does not implement the `Copy` trait |
55 | 65 | LL | xs @ [a, .., b] => {}
|
56 |
| - | -------------^- |
57 |
| - | | | |
58 |
| - | | value used here after move |
59 |
| - | value moved here |
| 66 | + | ^^^^^^-^^^^^^^^ |
| 67 | + | | | |
| 68 | + | | value partially moved here |
| 69 | + | value used here after partial move |
| 70 | + | |
| 71 | + = note: partial move occurs because value has type `U`, which does not implement the `Copy` trait |
60 | 72 |
|
61 |
| -error[E0382]: use of moved value |
62 |
| - --> $DIR/borrowck-move-and-move.rs:31:18 |
| 73 | +error[E0382]: use of partially moved value |
| 74 | + --> $DIR/borrowck-move-and-move.rs:31:9 |
63 | 75 | |
|
64 |
| -LL | match [u(), u(), u(), u()] { |
65 |
| - | -------------------- move occurs because value has type `[U; 4]`, which does not implement the `Copy` trait |
66 | 76 | LL | xs @ [_, ys @ .., _] => {}
|
67 |
| - | ---------^^^^^^^---- |
| 77 | + | ^^^^^^^^^-------^^^^ |
68 | 78 | | | |
|
69 |
| - | | value used here after move |
70 |
| - | value moved here |
| 79 | + | | value partially moved here |
| 80 | + | value used here after partial move |
| 81 | + | |
| 82 | + = note: partial move occurs because value has type `U`, which does not implement the `Copy` trait |
71 | 83 |
|
72 | 84 | error[E0382]: use of moved value
|
73 |
| - --> $DIR/borrowck-move-and-move.rs:24:16 |
| 85 | + --> $DIR/borrowck-move-and-move.rs:24:12 |
74 | 86 | |
|
75 | 87 | LL | fn fun(a @ b: U) {}
|
76 |
| - | ----^ |
| 88 | + | ^^^^- |
77 | 89 | | | |
|
78 |
| - | | value used here after move |
79 |
| - | value moved here |
| 90 | + | | value moved here |
| 91 | + | value used here after move |
80 | 92 | | move occurs because value has type `U`, which does not implement the `Copy` trait
|
81 | 93 |
|
82 | 94 | error: aborting due to 8 previous errors
|
|
0 commit comments