2019-11-11 04:39:52 -06:00
|
|
|
error[E0382]: use of moved value
|
2021-05-17 23:14:06 -05:00
|
|
|
--> $DIR/borrowck-move-and-move.rs:11:9
|
2019-11-11 04:39:52 -06:00
|
|
|
|
|
|
|
|
LL | let a @ b = U;
|
2022-09-03 17:55:53 -05:00
|
|
|
| ^ - - move occurs because value has type `U`, which does not implement the `Copy` trait
|
2019-11-11 04:39:52 -06:00
|
|
|
| | |
|
2020-11-01 12:35:55 -06:00
|
|
|
| | value moved here
|
|
|
|
| value used here after move
|
2022-11-02 23:22:24 -05:00
|
|
|
|
|
|
|
|
help: borrow this binding in the pattern to avoid moving the value
|
|
|
|
|
|
|
|
|
LL | let a @ ref b = U;
|
|
|
|
| +++
|
2019-11-11 04:39:52 -06:00
|
|
|
|
2020-11-01 12:35:55 -06:00
|
|
|
error[E0382]: use of partially moved value
|
2021-05-17 23:14:06 -05:00
|
|
|
--> $DIR/borrowck-move-and-move.rs:13:9
|
2019-11-11 04:39:52 -06:00
|
|
|
|
|
|
|
|
LL | let a @ (b, c) = (U, U);
|
2022-09-03 17:55:53 -05:00
|
|
|
| ^ - value partially moved here
|
|
|
|
| |
|
2020-11-01 12:35:55 -06:00
|
|
|
| value used here after partial move
|
|
|
|
|
|
|
|
|
= note: partial move occurs because value has type `U`, which does not implement the `Copy` trait
|
2022-11-02 23:22:24 -05:00
|
|
|
help: borrow this binding in the pattern to avoid moving the value
|
|
|
|
|
|
|
|
|
LL | let a @ (b, ref c) = (U, U);
|
|
|
|
| +++
|
2019-11-11 04:39:52 -06:00
|
|
|
|
2020-11-01 12:35:55 -06:00
|
|
|
error[E0382]: use of partially moved value
|
2021-05-17 23:14:06 -05:00
|
|
|
--> $DIR/borrowck-move-and-move.rs:15:9
|
2019-12-14 17:50:44 -06:00
|
|
|
|
|
|
|
|
LL | let a @ (b, c) = (u(), u());
|
2022-09-03 17:55:53 -05:00
|
|
|
| ^ - value partially moved here
|
|
|
|
| |
|
2020-11-01 12:35:55 -06:00
|
|
|
| value used here after partial move
|
|
|
|
|
|
|
|
|
= note: partial move occurs because value has type `U`, which does not implement the `Copy` trait
|
2022-11-02 23:22:24 -05:00
|
|
|
help: borrow this binding in the pattern to avoid moving the value
|
|
|
|
|
|
|
|
|
LL | let a @ (b, ref c) = (u(), u());
|
|
|
|
| +++
|
2019-12-14 17:50:44 -06:00
|
|
|
|
2020-11-03 00:45:41 -06:00
|
|
|
error[E0382]: use of moved value
|
2021-05-17 23:14:06 -05:00
|
|
|
--> $DIR/borrowck-move-and-move.rs:18:16
|
2019-11-11 04:39:52 -06:00
|
|
|
|
|
2020-11-03 00:45:41 -06:00
|
|
|
LL | match Ok(U) {
|
2021-01-28 10:01:36 -06:00
|
|
|
| ----- move occurs because value has type `Result<U, U>`, which does not implement the `Copy` trait
|
2019-11-11 04:39:52 -06:00
|
|
|
LL | a @ Ok(b) | a @ Err(b) => {}
|
2022-09-03 17:55:53 -05:00
|
|
|
| - ^ value used here after move
|
|
|
|
| |
|
2020-11-03 00:45:41 -06:00
|
|
|
| value moved here
|
2022-11-02 23:22:24 -05:00
|
|
|
|
|
|
|
|
help: borrow this binding in the pattern to avoid moving the value
|
|
|
|
|
|
|
|
|
LL | ref a @ Ok(b) | a @ Err(b) => {}
|
|
|
|
| +++
|
2019-11-11 04:39:52 -06:00
|
|
|
|
2020-11-03 00:45:41 -06:00
|
|
|
error[E0382]: use of moved value
|
2021-05-17 23:14:06 -05:00
|
|
|
--> $DIR/borrowck-move-and-move.rs:18:29
|
2019-11-11 04:39:52 -06:00
|
|
|
|
|
2020-11-03 00:45:41 -06:00
|
|
|
LL | match Ok(U) {
|
2021-01-28 10:01:36 -06:00
|
|
|
| ----- move occurs because value has type `Result<U, U>`, which does not implement the `Copy` trait
|
2019-11-11 04:39:52 -06:00
|
|
|
LL | a @ Ok(b) | a @ Err(b) => {}
|
2022-09-03 17:55:53 -05:00
|
|
|
| - ^ value used here after move
|
|
|
|
| |
|
2020-11-03 00:45:41 -06:00
|
|
|
| value moved here
|
2022-11-02 23:22:24 -05:00
|
|
|
|
|
|
|
|
help: borrow this binding in the pattern to avoid moving the value
|
|
|
|
|
|
|
|
|
LL | a @ Ok(b) | ref a @ Err(b) => {}
|
|
|
|
| +++
|
2019-11-11 04:39:52 -06:00
|
|
|
|
2020-11-01 12:35:55 -06:00
|
|
|
error[E0382]: use of partially moved value
|
2021-05-17 23:14:06 -05:00
|
|
|
--> $DIR/borrowck-move-and-move.rs:25:9
|
2019-12-14 20:50:55 -06:00
|
|
|
|
|
|
|
|
LL | xs @ [a, .., b] => {}
|
2022-09-03 17:55:53 -05:00
|
|
|
| ^^ - value partially moved here
|
|
|
|
| |
|
2020-11-01 12:35:55 -06:00
|
|
|
| value used here after partial move
|
|
|
|
|
|
|
|
|
= note: partial move occurs because value has type `U`, which does not implement the `Copy` trait
|
2022-11-02 23:22:24 -05:00
|
|
|
help: borrow this binding in the pattern to avoid moving the value
|
|
|
|
|
|
|
|
|
LL | xs @ [a, .., ref b] => {}
|
|
|
|
| +++
|
2019-12-14 20:50:55 -06:00
|
|
|
|
2020-11-01 12:35:55 -06:00
|
|
|
error[E0382]: use of partially moved value
|
2021-05-17 23:14:06 -05:00
|
|
|
--> $DIR/borrowck-move-and-move.rs:29:9
|
2019-12-14 20:50:55 -06:00
|
|
|
|
|
|
|
|
LL | xs @ [_, ys @ .., _] => {}
|
2022-09-03 17:55:53 -05:00
|
|
|
| ^^ -- value partially moved here
|
|
|
|
| |
|
2020-11-01 12:35:55 -06:00
|
|
|
| value used here after partial move
|
|
|
|
|
|
|
|
|
= note: partial move occurs because value has type `U`, which does not implement the `Copy` trait
|
2022-11-02 23:22:24 -05:00
|
|
|
help: borrow this binding in the pattern to avoid moving the value
|
|
|
|
|
|
|
|
|
LL | xs @ [_, ref ys @ .., _] => {}
|
|
|
|
| +++
|
2019-12-14 20:50:55 -06:00
|
|
|
|
|
|
|
error[E0382]: use of moved value
|
2021-05-17 23:14:06 -05:00
|
|
|
--> $DIR/borrowck-move-and-move.rs:22:12
|
2019-12-14 20:50:55 -06:00
|
|
|
|
|
|
|
|
LL | fn fun(a @ b: U) {}
|
2022-09-08 09:44:45 -05:00
|
|
|
| ^ - value moved here
|
|
|
|
| |
|
2020-11-01 12:35:55 -06:00
|
|
|
| value used here after move
|
2020-09-02 02:40:56 -05:00
|
|
|
| move occurs because value has type `U`, which does not implement the `Copy` trait
|
2019-12-14 20:50:55 -06:00
|
|
|
|
2020-01-18 19:47:01 -06:00
|
|
|
error: aborting due to 8 previous errors
|
2019-11-11 04:39:52 -06:00
|
|
|
|
2020-01-18 19:47:01 -06:00
|
|
|
For more information about this error, try `rustc --explain E0382`.
|