pub struct Mutex<T> { /* private fields */ }Implementations§
Trait Implementations§
Source§impl<E: Env> GlobalAlloc for Mutex<Allocator<E>>
impl<E: Env> GlobalAlloc for Mutex<Allocator<E>>
Source§unsafe fn alloc(&self, layout: Layout) -> *mut u8
unsafe fn alloc(&self, layout: Layout) -> *mut u8
Allocates memory as described by the given
layout. Read moreSource§unsafe fn alloc_zeroed(&self, layout: Layout) -> *mut u8
unsafe fn alloc_zeroed(&self, layout: Layout) -> *mut u8
Behaves like
alloc, but also ensures that the contents
are set to zero before being returned. Read moreimpl<T> Send for Mutex<T>where
T: Send,
impl<T> Sync for Mutex<T>where
T: Send,
Auto Trait Implementations§
impl<T> !Freeze for Mutex<T>
impl<T> !RefUnwindSafe for Mutex<T>
impl<T> Unpin for Mutex<T>where
T: Unpin,
impl<T> UnwindSafe for Mutex<T>where
T: UnwindSafe,
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