pub trait ResError: Sized {
type V;
type E: Debug + Display + Send + Sync + 'static;
// Required method
fn res_err(self) -> Result<Self::V, Self::E>;
// Provided methods
fn e_str(self, s: &'static str) -> Result<Self::V> { ... }
fn e_string(self, s: String) -> Result<Self::V> { ... }
}
Required Associated Types§
Required Methods§
Provided Methods§
fn e_str(self, s: &'static str) -> Result<Self::V>
fn e_string(self, s: String) -> Result<Self::V>
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.