]> git.proxmox.com Git - rustc.git/blob - tests/ui/nll/reference-carried-through-struct-field.stderr
New upstream version 1.68.2+dfsg1
[rustc.git] / tests / ui / nll / reference-carried-through-struct-field.stderr
1 error[E0503]: cannot use `x` because it was mutably borrowed
2 --> $DIR/reference-carried-through-struct-field.rs:6:5
3 |
4 LL | let wrapper = Wrap { w: &mut x };
5 | ------ borrow of `x` occurs here
6 LL | x += 1;
7 | ^^^^^^ use of borrowed `x`
8 LL | *wrapper.w += 1;
9 | --------------- borrow later used here
10
11 error: aborting due to previous error
12
13 For more information about this error, try `rustc --explain E0503`.