pub struct TempRefMut<T: ?Sized>(/* private fields */);
Expand description
The canonical implementation of TempReprMut
, representing a single mutable reference.
This is not necessarily very useful on its own, but forms the basis of composition via tuples.
Trait Implementations§
Source§impl<T: ?Sized> Deref for TempRefMut<T>
impl<T: ?Sized> Deref for TempRefMut<T>
Source§impl<T: ?Sized> DerefMut for TempRefMut<T>
impl<T: ?Sized> DerefMut for TempRefMut<T>
Source§impl<T: Ord + ?Sized> Ord for TempRefMut<T>
impl<T: Ord + ?Sized> Ord for TempRefMut<T>
Source§fn cmp(&self, other: &TempRefMut<T>) -> Ordering
fn cmp(&self, other: &TempRefMut<T>) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl<T: PartialOrd + ?Sized> PartialOrd for TempRefMut<T>
impl<T: PartialOrd + ?Sized> PartialOrd for TempRefMut<T>
Source§impl<T: ?Sized> TempRepr for TempRefMut<T>
impl<T: ?Sized> TempRepr for TempRefMut<T>
Source§impl<T: ?Sized> TempReprMut for TempRefMut<T>
impl<T: ?Sized> TempReprMut for TempRefMut<T>
Source§type Mutable<'a> = &'a mut T
where
Self: 'a
type Mutable<'a> = &'a mut T where Self: 'a
The type that
Self
is a temporary representation of. May contain mutable references of
lifetime 'a
.Source§unsafe fn new_temp_mut(obj: Self::Mutable<'_>) -> Self
unsafe fn new_temp_mut(obj: Self::Mutable<'_>) -> Self
Converts the given object to a temporary representation without a lifetime parameter. Read more
Source§fn get_mut(&mut self) -> Self::Mutable<'_>
fn get_mut(&mut self) -> Self::Mutable<'_>
Converts from a mutable reference to the temporary representation back to the original type,
with a restricted lifetime.
Source§fn get_mut_pinned(self: Pin<&mut Self>) -> Self::Mutable<'_>
fn get_mut_pinned(self: Pin<&mut Self>) -> Self::Mutable<'_>
Like
TempReprMut::get_mut
, but takes a pinned mutable reference to Self
.Source§impl<T: ?Sized> TempReprMutChk for TempRefMut<T>
impl<T: ?Sized> TempReprMutChk for TempRefMut<T>
type SwapChkData = NonNull<T>
Source§fn swap_chk_data(&self) -> Self::SwapChkData
fn swap_chk_data(&self) -> Self::SwapChkData
Obtains an object (usually a copy of the internal state of
self
) that can be used to check
whether self
was swapped with another instance of Self
in such a way that the safety
rules of TempReprMutChk
are violated.impl<T: Eq + ?Sized> Eq for TempRefMut<T>
impl<T: ?Sized + Send> Send for TempRefMut<T>
impl<T: ?Sized> StructuralPartialEq for TempRefMut<T>
impl<T: ?Sized + Sync> Sync for TempRefMut<T>
Auto Trait Implementations§
impl<T> Freeze for TempRefMut<T>where
T: ?Sized,
impl<T> RefUnwindSafe for TempRefMut<T>where
T: RefUnwindSafe + ?Sized,
impl<T> Unpin for TempRefMut<T>where
T: ?Sized,
impl<T> UnwindSafe for TempRefMut<T>where
T: RefUnwindSafe + ?Sized,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more