]> git.lizzy.rs Git - rust.git/blob - src/test/ui/hygiene/fields-move.stderr
Rollup merge of #90202 - matthewjasper:xcrate-hygiene, r=petrochenkov
[rust.git] / src / test / ui / hygiene / fields-move.stderr
1 error[E0382]: use of moved value: `foo.x`
2   --> $DIR/fields-move.rs:18:9
3    |
4 LL |         $foo.x
5    |         ^^^^^^ value used here after move
6 ...
7 LL |     assert_two_copies(copy_modern!(foo), foo.x);
8    |                                          ----- value moved here
9 LL |     assert_two_copies(copy_legacy!(foo), foo.x);
10    |                       ----------------- in this macro invocation
11    |
12    = note: move occurs because `foo.x` has type `NonCopy`, which does not implement the `Copy` trait
13    = note: this error originates in the macro `copy_legacy` (in Nightly builds, run with -Z macro-backtrace for more info)
14
15 error[E0382]: use of moved value: `foo.x`
16   --> $DIR/fields-move.rs:28:42
17    |
18 LL |    $foo.x
19    |    ------ value moved here
20 ...
21 LL |     assert_two_copies(copy_modern!(foo), foo.x);
22    |                                          ^^^^^ value used here after move
23    |
24    = note: move occurs because `foo.x` has type `NonCopy`, which does not implement the `Copy` trait
25
26 error[E0382]: use of moved value: `foo.x`
27   --> $DIR/fields-move.rs:29:42
28    |
29 LL |         $foo.x
30    |         ------ value moved here
31 ...
32 LL |     assert_two_copies(copy_legacy!(foo), foo.x);
33    |                                          ^^^^^ value used here after move
34    |
35    = note: move occurs because `foo.x` has type `NonCopy`, which does not implement the `Copy` trait
36
37 error: aborting due to 3 previous errors
38
39 For more information about this error, try `rustc --explain E0382`.