diff options
Diffstat (limited to 'src/libs/intertrait/cast/error.rs')
-rw-r--r-- | src/libs/intertrait/cast/error.rs | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/libs/intertrait/cast/error.rs b/src/libs/intertrait/cast/error.rs new file mode 100644 index 0000000..e4211b1 --- /dev/null +++ b/src/libs/intertrait/cast/error.rs @@ -0,0 +1,17 @@ +use std::fmt; +use std::fmt::{Display, Formatter}; + +use error_stack::Context; + +#[derive(Debug)] +pub struct CastError; + +impl Display for CastError +{ + fn fmt(&self, fmt: &mut Formatter<'_>) -> fmt::Result + { + fmt.write_str("Failed to cast between traits") + } +} + +impl Context for CastError {} |