pub struct TypedPtrMut<'mem, T: ?Sized>(/* private fields */);Expand description
A pointer to an uninitialized value with a lifetime.
Implementations§
Source§impl<'mem, T: ?Sized> TypedPtrMut<'mem, T>
impl<'mem, T: ?Sized> TypedPtrMut<'mem, T>
Sourcepub const fn new(ptr: &'mem mut T) -> Self
pub const fn new(ptr: &'mem mut T) -> Self
Creates a new typed pointer from a reference
Sourcepub const fn get_mut(self) -> &'mem mut T
pub const fn get_mut(self) -> &'mem mut T
Unwraps the typed pointer as a reference
Trait Implementations§
Source§impl<T: ?Sized> Debug for TypedPtrMut<'_, T>
impl<T: ?Sized> Debug for TypedPtrMut<'_, T>
Source§impl<'mem, T: ?Sized> From<&'mem mut T> for TypedPtrMut<'mem, T>
impl<'mem, T: ?Sized> From<&'mem mut T> for TypedPtrMut<'mem, T>
Source§fn from(value: &'mem mut T) -> Self
fn from(value: &'mem mut T) -> Self
Converts to this type from the input type.
Source§impl<'mem, T: ?Sized> From<TypedPtrMut<'mem, T>> for PtrMut<'mem>
impl<'mem, T: ?Sized> From<TypedPtrMut<'mem, T>> for PtrMut<'mem>
Source§fn from(ptr: TypedPtrMut<'mem, T>) -> Self
fn from(ptr: TypedPtrMut<'mem, T>) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl<'mem, T> Freeze for TypedPtrMut<'mem, T>where
T: ?Sized,
impl<'mem, T> RefUnwindSafe for TypedPtrMut<'mem, T>where
T: RefUnwindSafe + ?Sized,
impl<'mem, T> !Send for TypedPtrMut<'mem, T>
impl<'mem, T> !Sync for TypedPtrMut<'mem, T>
impl<'mem, T> Unpin for TypedPtrMut<'mem, T>where
T: ?Sized,
impl<'mem, T> !UnwindSafe for TypedPtrMut<'mem, T>
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