pub trait OptionExt: Sized + Sealed {
type T;
// Required methods
fn is_none_or(self, f: impl FnOnce(Self::T) -> bool) -> bool;
fn contains<U>(&self, u: &U) -> bool
where Self::T: PartialEq<U>;
fn unwrap_none(self)
where Self::T: Debug;
fn expect_none(self, msg: &str)
where Self::T: Debug;
}Required Associated Types§
Required Methods§
fn is_none_or(self, f: impl FnOnce(Self::T) -> bool) -> bool
fn contains<U>(&self, u: &U) -> bool
fn unwrap_none(self)
fn expect_none(self, msg: &str)
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.