2 ms·
> 2. You can't have multiple mutable references at the same time. If I understood the issue correctly, only one of the references would be a mutable one, so th
by cesarb 7y ago
> 2. You can't have multiple mutable references at the same time.
If I understood the issue correctly, only one of the references would be a mutable one, so the way Rust could have caught the bug would instead be the related rule: "you can't have an immutable reference and a mutable reference at the same time".