Enum r3::sync::mutex::TryLockError
source · #[repr(i8)]
pub enum TryLockError<Guard> {
BadContext,
WouldDeadlock,
WouldBlock,
BadParam,
Abandoned(Guard),
}
Available on crate feature
sync
only.Expand description
Error type of GenericMutex::try_lock
.
Variants§
BadContext
CPU Lock is active, or the current context is not a task context.
WouldDeadlock
The current task already owns the mutex.
WouldBlock
The lock could not be acquire at this time because the operation would otherwise block.
BadParam
The mutex was created with the protocol attribute having the value
Ceiling
and the current task’s priority is higher than the
mutex’s priority ceiling.
Abandoned(Guard)
The previous owning task exited while holding the mutex lock. The current task shall hold the mutex lock, but is up to make the state consistent.