Function source_chain::to_string
source · pub fn to_string(e: &(dyn Error + 'static)) -> String
Expand description
A helper function to format an error with its source chain.
This function works with both &Error
and Box<dyn Error>
. When passing a boxed error,
make sure to dereference it using &*e
.