diff --git a/pkstrings/src/pkstring.rs b/pkstrings/src/pkstring.rs index f663561..15af130 100644 --- a/pkstrings/src/pkstring.rs +++ b/pkstrings/src/pkstring.rs @@ -22,6 +22,7 @@ use std::convert::TryFrom; use std::fmt; +use std::error::Error as StdError; use std::ops::Deref; const fn in_range(ord: u8) -> bool { @@ -111,6 +112,8 @@ pub enum Error { InvalidCharacter(char), } +impl StdError for Error {} + impl fmt::Display for Error { fn fmt(&self, f: &mut fmt::Formatter) -> Result<(), fmt::Error> { match self {