From 3c1a0ffb4b57bcaaee399625a4e20d4f3c0c96aa Mon Sep 17 00:00:00 2001 From: Matthias Beyer Date: Fri, 19 Mar 2021 09:38:17 +0100 Subject: Add support for unsigned integers Signed-off-by: Matthias Beyer --- src/error.rs | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/error.rs') diff --git a/src/error.rs b/src/error.rs index db5813e..84984ba 100644 --- a/src/error.rs +++ b/src/error.rs @@ -10,6 +10,8 @@ pub enum Unexpected { Bool(bool), I64(i64), I128(i128), + U64(u64), + U128(u128), Float(f64), Str(String), Unit, @@ -23,6 +25,8 @@ impl fmt::Display for Unexpected { Unexpected::Bool(b) => write!(f, "boolean `{}`", b), Unexpected::I64(i) => write!(f, "integer 64 bit `{}`", i), Unexpected::I128(i) => write!(f, "integer 128 bit `{}`", i), + Unexpected::U64(i) => write!(f, "unsigned integer 64 bit `{}`", i), + Unexpected::U128(i) => write!(f, "unsigned integer 128 bit `{}`", i), Unexpected::Float(v) => write!(f, "floating point `{}`", v), Unexpected::Str(ref s) => write!(f, "string {:?}", s), Unexpected::Unit => write!(f, "unit value"), -- cgit v1.2.3