]> git.lizzy.rs Git - rust.git/blob - tests/ui/borrowck/two-phase-reservation-sharing-interference.nll_target.stderr
Rollup merge of #106726 - cmorin6:fix-comment-typos, r=Nilstrieb
[rust.git] / tests / ui / borrowck / two-phase-reservation-sharing-interference.nll_target.stderr
1 error[E0502]: cannot borrow `vec` as mutable because it is also borrowed as immutable
2   --> $DIR/two-phase-reservation-sharing-interference.rs:32:17
3    |
4 LL |         let shared = &vec;
5    |                      ---- immutable borrow occurs here
6 ...
7 LL |         delay = &mut vec;
8    |                 ^^^^^^^^ mutable borrow occurs here
9 ...
10 LL |         shared[0];
11    |         ------ immutable borrow later used here
12
13 error: aborting due to previous error
14
15 For more information about this error, try `rustc --explain E0502`.