rust/src/test/ui/issues/issue-17263.nll.stderr
2018-11-05 15:26:02 +01:00

15 lines
405 B
Plaintext

error: compilation successful
--> $DIR/issue-17263.rs:15:1
|
LL | / fn main() { //[nll]~ ERROR compilation successful
LL | | let mut x: Box<_> = box Foo { a: 1, b: 2 };
LL | | let (a, b) = (&mut x.a, &mut x.b);
LL | | //[ast]~^ ERROR cannot borrow `x` (via `x.b`) as mutable more than once at a time
... |
LL | | use_mut(a);
LL | | }
| |_^
error: aborting due to previous error