pub struct LockFreeStatic<T, D, F: Fn() -> T = fn() -> T> { /* private fields */ }Expand description
Convenience wrapper for static initialization of cells.
Should be explicitly initialized (by init call) because
initialization is fallible and therefore cannot be done automatically on dereference.
Implementations§
Source§impl<T, D, F: Fn() -> T> LockFreeStatic<T, D, F>
impl<T, D, F: Fn() -> T> LockFreeStatic<T, D, F>
Source§impl<T, F: Fn() -> T> LockFreeStatic<T, OnceCell<T>, F>
impl<T, F: Fn() -> T> LockFreeStatic<T, OnceCell<T>, F>
Trait Implementations§
Auto Trait Implementations§
impl<T, D, F> Freeze for LockFreeStatic<T, D, F>
impl<T, D, F> RefUnwindSafe for LockFreeStatic<T, D, F>where
D: RefUnwindSafe,
F: RefUnwindSafe,
impl<T, D, F> Send for LockFreeStatic<T, D, F>
impl<T, D, F> Sync for LockFreeStatic<T, D, F>
impl<T, D, F> Unpin for LockFreeStatic<T, D, F>
impl<T, D, F> UnwindSafe for LockFreeStatic<T, D, F>where
D: UnwindSafe,
F: 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