blob: 8c40b4db4f791699ee8a6bdf6858190a81b9fb95 [file] [log] [blame]
error[E0382]: use of moved value: `x`
--> $DIR/moves-based-on-type-distribute-copy-over-paren.rs:21:12
|
LL | let _y = Foo { f:x };
| - value moved here
LL | //~^ NOTE value moved here
LL | touch(&x); //~ ERROR use of moved value: `x`
| ^ value used here after move
|
= note: move occurs because `x` has type `std::string::String`, which does not implement the `Copy` trait
error[E0382]: use of moved value: `x`
--> $DIR/moves-based-on-type-distribute-copy-over-paren.rs:30:12
|
LL | let _y = Foo { f:(((x))) };
| ------- value moved here
LL | //~^ NOTE value moved here
LL | touch(&x); //~ ERROR use of moved value: `x`
| ^ value used here after move
|
= note: move occurs because `x` has type `std::string::String`, which does not implement the `Copy` trait
error: aborting due to 2 previous errors
For more information about this error, try `rustc --explain E0382`.