pub struct Flag {
failed: AtomicBool,
}
Fields§
§failed: AtomicBool
Implementations§
source§impl Flag
impl Flag
pub const fn new() -> Flag
sourcepub fn borrow(&self) -> LockResult<()>
pub fn borrow(&self) -> LockResult<()>
Check the flag for an unguarded borrow, where we only care about existing poison.
sourcepub fn guard(&self) -> LockResult<Guard>
pub fn guard(&self) -> LockResult<Guard>
Check the flag for a guarded borrow, where we may also set poison when done
.
pub fn done(&self, guard: &Guard)
pub fn get(&self) -> bool
pub fn clear(&self)
Auto Trait Implementations§
impl RefUnwindSafe for Flag
impl Send for Flag
impl Sync for Flag
impl Unpin for Flag
impl UnwindSafe for Flag
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