pub struct StretchedMut<T: ?Sized>(/* private fields */);
Expand description
A type representing a stretched &mut T
reference. Has the same representation as a *mut T
.
Trait Implementations§
Source§impl<T: Clone + ?Sized> Clone for StretchedMut<T>
impl<T: Clone + ?Sized> Clone for StretchedMut<T>
Source§fn clone(&self) -> StretchedMut<T>
fn clone(&self) -> StretchedMut<T>
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl<T: 'static> Stretched for StretchedMut<T>
impl<T: 'static> Stretched for StretchedMut<T>
Source§type Parameterized<'a> = &'a mut T
type Parameterized<'a> = &'a mut T
The parameterized type, which must be bit-equivalent to the unparameterized
Self
type. It
must have the same size, same pointer size, same alignment, same everything.Source§unsafe fn lengthen(this: Self::Parameterized<'_>) -> Self
unsafe fn lengthen(this: Self::Parameterized<'_>) -> Self
Source§unsafe fn shorten<'a>(this: Self) -> Self::Parameterized<'a>
unsafe fn shorten<'a>(this: Self) -> Self::Parameterized<'a>
Shorten the lifetime of a
'static
self to some arbitrary Stretched::Parameterized
.
This is intended strictly as the inverse of Stretched::lengthen
, and makes no guarantees
about its behavior if not used as such. Read moreSource§unsafe fn shorten_mut<'a>(this: &mut Self) -> &mut Self::Parameterized<'a>
unsafe fn shorten_mut<'a>(this: &mut Self) -> &mut Self::Parameterized<'a>
Equivalent to
Stretched::shorten
but operates on a mutable reference to the stretched
type. Read moreSource§unsafe fn shorten_ref<'a>(this: &Self) -> &Self::Parameterized<'a>
unsafe fn shorten_ref<'a>(this: &Self) -> &Self::Parameterized<'a>
Equivalent to
Stretched::shorten
but operates on an immutable reference to the stretched
type. Read moreimpl<T: Copy + ?Sized> Copy for StretchedMut<T>
impl<T: Send> Send for StretchedMut<T>
impl<T: Sync> Sync for StretchedMut<T>
Auto Trait Implementations§
impl<T> Freeze for StretchedMut<T>where
T: ?Sized,
impl<T> RefUnwindSafe for StretchedMut<T>where
T: RefUnwindSafe + ?Sized,
impl<T> Unpin for StretchedMut<T>where
T: ?Sized,
impl<T> UnwindSafe for StretchedMut<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