rust/src/test/ui/unop-move-semantics.stderr
Vadim Petrochenkov fa72a81bea Update tests
2019-03-11 23:10:26 +03:00

46 lines
1.2 KiB
Plaintext

error[E0382]: use of moved value: `x`
--> $DIR/unop-move-semantics.rs:8:5
|
LL | !x;
| - value moved here
LL |
LL | x.clone();
| ^ value used here after move
|
= note: move occurs because `x` has type `T`, which does not implement the `Copy` trait
error[E0505]: cannot move out of `x` because it is borrowed
--> $DIR/unop-move-semantics.rs:15:6
|
LL | let m = &x;
| - borrow of `x` occurs here
...
LL | !x;
| ^ move out of `x` occurs here
error[E0505]: cannot move out of `y` because it is borrowed
--> $DIR/unop-move-semantics.rs:17:6
|
LL | let n = &mut y;
| - borrow of `y` occurs here
...
LL | !y;
| ^ move out of `y` occurs here
error[E0507]: cannot move out of borrowed content
--> $DIR/unop-move-semantics.rs:24:6
|
LL | !*m;
| ^^ cannot move out of borrowed content
error[E0507]: cannot move out of borrowed content
--> $DIR/unop-move-semantics.rs:26:6
|
LL | !*n;
| ^^ cannot move out of borrowed content
error: aborting due to 5 previous errors
Some errors occurred: E0382, E0505, E0507.
For more information about an error, try `rustc --explain E0382`.