]> git.lizzy.rs Git - rust.git/blobdiff - src/libserialize/hex.rs
Deprecate Error::description for real
[rust.git] / src / libserialize / hex.rs
index a2a5a3cb59c770d4ea14a865c32fc6dd68d6b8d5..cfb165a3d4397d4848774f6e1b0aece763a49c24 100644 (file)
@@ -68,14 +68,7 @@ fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
     }
 }
 
-impl error::Error for FromHexError {
-    fn description(&self) -> &str {
-        match *self {
-            InvalidHexCharacter(..) => "invalid character",
-            InvalidHexLength => "invalid length",
-        }
-    }
-}
+impl error::Error for FromHexError {}
 
 impl FromHex for str {
     /// Converts any hexadecimal encoded string (literal, `@`, `&`, or `~`)