]> git.lizzy.rs Git - rust.git/blob - src/test/ui/issues/issue-40402-ref-hints/issue-40402-2.nll.stderr
tests: prefer edition: directives to compile-flags:--edition.
[rust.git] / src / test / ui / issues / issue-40402-ref-hints / issue-40402-2.nll.stderr
1 error[E0507]: cannot move out of borrowed content
2   --> $DIR/issue-40402-2.rs:15:18
3    |
4 LL |     let (a, b) = x[0]; //~ ERROR cannot move out of indexed content
5    |          -  -    ^^^^
6    |          |  |    |
7    |          |  |    cannot move out of borrowed content
8    |          |  |    help: consider using a reference instead: `&x[0]`
9    |          |  move occurs because b has type `std::string::String`, which does not implement the `Copy` trait
10    |          move occurs because a has type `std::string::String`, which does not implement the `Copy` trait
11
12 error: aborting due to previous error
13
14 For more information about this error, try `rustc --explain E0507`.