pub trait RefMut<'a, T> {
// Required method
fn from_ref_mut(val: &'a mut T) -> Self;
}
Expand description
A trait for things that are “close enough” to &'a mut T
.
Required Methods§
Sourcefn from_ref_mut(val: &'a mut T) -> Self
fn from_ref_mut(val: &'a mut T) -> Self
Obtains this value from a mutable reference, showing that it’s possible.
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.
Implementations on Foreign Types§
Source§impl<'a, K, V, R: Ref<'a, K>> RefMut<'a, (K, V)> for (R, &'a mut V)
impl<'a, K, V, R: Ref<'a, K>> RefMut<'a, (K, V)> for (R, &'a mut V)
Pull the key out of a key-value pair.
fn from_ref_mut(val: &'a mut (K, V)) -> (R, &'a mut V)
Source§impl<'a, T> RefMut<'a, T> for &'a mut T
impl<'a, T> RefMut<'a, T> for &'a mut T
Identity implementation.