error[E07002]: mutable ownership violated ┌─ tests/move_check/borrows/copy_combo_invalid.move:14:9 │ 13 │ if (cond) f = &mut s.f else f = &mut other.f; │ -------- It is still being mutably borrowed by this reference 14 │ copy s; │ ^^^^^^ Invalid copy of variable 's' error[E07002]: mutable ownership violated ┌─ tests/move_check/borrows/copy_combo_invalid.move:23:9 │ 22 │ if (cond) f = &mut s else f = other; │ ------ It is still being mutably borrowed by this reference 23 │ copy s; │ ^^^^^^ Invalid copy of variable 's' error[E07002]: mutable ownership violated ┌─ tests/move_check/borrows/copy_combo_invalid.move:32:9 │ 31 │ if (cond) f = id_mut(&mut s) else f = other; │ -------------- It is still being mutably borrowed by this reference 32 │ copy s; │ ^^^^^^ Invalid copy of variable 's' error[E07002]: mutable ownership violated ┌─ tests/move_check/borrows/copy_combo_invalid.move:40:21 │ 39 │ let f = &mut s.f; │ -------- It is still being mutably borrowed by this reference 40 │ if (cond) { copy s; }; │ ^^^^^^ Invalid copy of variable 's'