impl_from_error

Macro impl_from_error 

Source
macro_rules! impl_from_error {
    ($ErrorName:ident,$source:ty,$ty:expr) => { ... };
}
Expand description

Macro to implement from converters for error types generated with impl_error!

impl From<source> for ErrorName {
    fn from(value: source) -> Self {
        ErrorName {
            error_type: ty,
            msg: value.to_string(),
        }
    }
}