2020-01-27 22:26:37 +00:00
|
|
|
error[E0502]: cannot borrow `y` as immutable because it is also borrowed as mutable
|
2024-04-11 13:15:34 +00:00
|
|
|
--> $DIR/dropck-resume.rs:26:13
|
2020-01-27 22:26:37 +00:00
|
|
|
|
|
|
|
|
LL | let z = &mut y;
|
|
|
|
| ------ mutable borrow occurs here
|
|
|
|
...
|
|
|
|
LL | r = y.as_ref().unwrap();
|
2023-06-22 20:30:23 +00:00
|
|
|
| ^ immutable borrow occurs here
|
2020-01-27 22:26:37 +00:00
|
|
|
LL |
|
|
|
|
LL | }
|
2023-10-19 21:46:28 +00:00
|
|
|
| - mutable borrow might be used here, when `g` is dropped and runs the destructor for coroutine
|
2020-01-27 22:26:37 +00:00
|
|
|
|
2023-11-21 15:44:16 +00:00
|
|
|
error: aborting due to 1 previous error
|
2020-01-27 22:26:37 +00:00
|
|
|
|
|
|
|
For more information about this error, try `rustc --explain E0502`.
|