External Publication
Visit Post

Just `mut` alongside `let mut`

Rust Internals [Unofficial] March 17, 2026
Source

Huh? Unlike other languages, shadowing in rust is common practise. You transfer ownership of some variable to a fiction and assign the result back to the same name. Switching between mut and non-mut bindings is also common.

I would be very surprised if people commonly lint against shadowing rather than take advantage of it.

Discussion in the ATmosphere

Loading comments...