ErrorExt

Trait ErrorExt 

Source
pub trait ErrorExt {
    // Required methods
    fn display_chain(&self) -> String;
    fn display_chain_with_msg<S: AsRef<str>>(&self, msg: S) -> String;
}
Expand description

Used to generate string representations of error chains.

Required Methods§

Source

fn display_chain(&self) -> String

Creates a string representation of the entire error chain.

Source

fn display_chain_with_msg<S: AsRef<str>>(&self, msg: S) -> String

Like Self::display_chain but with an extra message at the start of the chain.

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.

Implementors§

Source§

impl<E: Error> ErrorExt for E