Enum panic_control::Outcome [] [src]

pub enum Outcome<T, P> {
    NoPanic(T),
    Panicked(P),
}

Enumerates the expected outcomes from joining a panic-checked thread.

Outcome values are returned in the Ok result variant of the join() method of a CheckedJoinHandle.

Variants

Indicates that the thread closure has returned normally, and provides the return value.

Indicates that the thread has panicked with the expected type, and provides the panic value.

Methods

impl<T, P> Outcome<T, P>
[src]

[src]

Tests whether the value contains the variant Panicked.

Trait Implementations

impl<T: Copy, P: Copy> Copy for Outcome<T, P>
[src]

impl<T: Clone, P: Clone> Clone for Outcome<T, P>
[src]

[src]

Returns a copy of the value. Read more

1.0.0
[src]

Performs copy-assignment from source. Read more

impl<T: Debug, P: Debug> Debug for Outcome<T, P>
[src]

[src]

Formats the value using the given formatter. Read more

impl<T: PartialEq, P: PartialEq> PartialEq for Outcome<T, P>
[src]

[src]

This method tests for self and other values to be equal, and is used by ==. Read more

[src]

This method tests for !=.

impl<T: Eq, P: Eq> Eq for Outcome<T, P>
[src]

Auto Trait Implementations

impl<T, P> Send for Outcome<T, P> where
    P: Send,
    T: Send

impl<T, P> Sync for Outcome<T, P> where
    P: Sync,
    T: Sync