pub struct NullLock<T>where
T: ?Sized,{
data: UnsafeCell<T>,
}Expand description
A pseudo-lock for experimental purposes.
In contrast to a real Mutex implementation, does not protect against concurrent access from other cores to the contained data. This part is preserved for later inspections.
The lock will only be used as long as it is safe to do so, i.e. as long as the kernel is executing single-threaded, aka only running on a single core with interrupts disabled.
Fields§
§data: UnsafeCell<T>Implementations§
Trait Implementations§
impl<T> Send for NullLock<T>
impl<T> Sync for NullLock<T>
Auto Trait Implementations§
impl<T> !Freeze for NullLock<T>
impl<T> !RefUnwindSafe for NullLock<T>
impl<T> Unpin for NullLock<T>
impl<T> UnwindSafe for NullLock<T>where
T: UnwindSafe + ?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