]> git.lizzy.rs Git - mt_ser.git/blobdiff - src/lib.rs
derive deserialize
[mt_ser.git] / src / lib.rs
index 0019d1c0b63e023abc5befa8b21e824a8e972d6b..f57e487eaa8c635e4eddee7196fe4fe85613fd20 100644 (file)
@@ -45,8 +45,10 @@ pub enum DeserializeError {
     TooBig(#[from] TryFromIntError),
     #[error("invalid UTF-16: {0}")]
     InvalidUtf16(#[from] std::char::DecodeUtf16Error),
-    #[error("unimplemented")]
-    Unimplemented,
+    #[error("invalid {0} enum variant {1}")]
+    InvalidEnumVariant(&'static str, u64),
+    #[error("invalid constant - wanted: {0} - got: {1}")]
+    InvalidConst(u64, u64),
 }
 
 impl From<Infallible> for DeserializeError {