diff --git a/src/lib.rs b/src/lib.rs index 1bf03816..900eed5f 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -15,6 +15,7 @@ //! For usage, check the documentation on the `Jid` struct. use std::convert::Into; +use std::error::Error as StdError; use std::fmt; use std::str::FromStr; @@ -35,6 +36,8 @@ pub enum JidParseError { EmptyResource, } +impl StdError for JidParseError {} + impl fmt::Display for JidParseError { fn fmt(&self, fmt: &mut fmt::Formatter) -> fmt::Result { write!(fmt, "{}", match self {