pub struct BlockOnDeadlock {
pub kind: BlockOnDeadlockKind,
pub park_deadline: Option<Duration>,
}Expand description
Typed panic payload for a self-detected block_on deadlock. Thrown with
std::panic::panic_any at the park DECISION (never merely on a Pending
return, because a self-waking future is not a deadlock), so the
runtime fails loudly instead of freezing the thread (and, in the
CurrentThread-on-JS-thread case, the whole JS event loop, where not even
test-harness timeouts can fire). When the panic unwinds out of a spawned
task’s poll, JoinError::from_panic preserves this diagnostic’s message.
Fields§
§kind: BlockOnDeadlockKind§park_deadline: Option<Duration>The armed deadline for the deadline-based kinds; None for the provable
threadless case.
Trait Implementations§
Source§impl Clone for BlockOnDeadlock
impl Clone for BlockOnDeadlock
Source§fn clone(&self) -> BlockOnDeadlock
fn clone(&self) -> BlockOnDeadlock
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for BlockOnDeadlock
impl Debug for BlockOnDeadlock
Source§impl Display for BlockOnDeadlock
impl Display for BlockOnDeadlock
Source§impl Error for BlockOnDeadlock
impl Error for BlockOnDeadlock
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Auto Trait Implementations§
impl Freeze for BlockOnDeadlock
impl RefUnwindSafe for BlockOnDeadlock
impl Send for BlockOnDeadlock
impl Sync for BlockOnDeadlock
impl Unpin for BlockOnDeadlock
impl UnsafeUnpin for BlockOnDeadlock
impl UnwindSafe for BlockOnDeadlock
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more