conv::errors

Trait UnwrapOrInvalid

Source
pub trait UnwrapOrInvalid {
    type Output;

    // Required method
    fn unwrap_or_invalid(self) -> Self::Output;
}
Expand description

Unwrap a conversion by replacing a failure with an invalid sentinel value.

Required Associated Types§

Source

type Output

The result of unwrapping.

Required Methods§

Source

fn unwrap_or_invalid(self) -> Self::Output

Either unwraps the successfully converted value, or returns the output type’s invalid sentinel value.

Implementations on Foreign Types§

Source§

impl<T, E> UnwrapOrInvalid for Result<T, E>
where T: InvalidSentinel,

Implementors§