3 ms·
Yes, I'm suggesting it should do the right thing for the code the loop is actually trying to execute. I personally think this is exactly what Rust and its users
by 59nadir 1y ago
Yes, I'm suggesting it should do the right thing for the code the loop is actually trying to execute. I personally think this is exactly what Rust and its users have signed up for. I might be mistaken about that, but I think it's in line with the more general view that Rust is attempting to be as close as it can get to a language that reads like it has a garbage collector without having one.
- DougBTX 1y ago> the more general view that Rust is attempting to be as close as it can get to a language that reads like it has a garbage collector without having one. I've used Rust a fair amount, and I've never seen that expressed as a goal. A couple of general principles followed by Rust are to prefer explicit code over implicit conversions and to support local reasoning. Those are both present here: the borrow needs to be made explicitly, rather than implicitly based on code later on.
- Klonoar 1y agoThis is not at all what we signed up for. The explicit-ness is the point.