pub trait WithInnerMut<T> {
// Required method
fn with_inner_mut<R>(&self, f: impl FnOnce(&mut T) -> R) -> R;
}Expand description
Trait to apply a function to a mutable reference of an internally mutable variable.
Required Methods§
Sourcefn with_inner_mut<R>(&self, f: impl FnOnce(&mut T) -> R) -> R
fn with_inner_mut<R>(&self, f: impl FnOnce(&mut T) -> R) -> R
Apply a function to mutate this value.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.