Abstracting over mutability in Rust

It is common to see the statement that “Rust cannot abstract over mutability”. Indeed,
many functions in the standard library have an immutable and a mutable variant, e.g.
RefCell::borrow() and RefCell::borrow_mut(). However, in some cases,
such as…

Similar