From 861a7be7d419a1fff04869cea1f3f8a1cc060611 Mon Sep 17 00:00:00 2001 From: Abid Omar Date: Mon, 11 Mar 2019 18:38:50 +0100 Subject: [PATCH] Add PartialEq to Toml::de Add PartialEq trait to Error, ErrorInner and ErrorKind. Relevant issue: https://github.com/alexcrichton/toml-rs/issues/291 --- src/de.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/de.rs b/src/de.rs index 437ead5..92db5d0 100644 --- a/src/de.rs +++ b/src/de.rs @@ -79,12 +79,12 @@ where } /// Errors that can occur when deserializing a type. -#[derive(Debug, Clone)] +#[derive(Debug, PartialEq, Clone)] pub struct Error { inner: Box, } -#[derive(Debug, Clone)] +#[derive(Debug, PartialEq, Clone)] struct ErrorInner { kind: ErrorKind, line: Option, @@ -94,7 +94,7 @@ struct ErrorInner { } /// Errors that can occur when deserializing a type. -#[derive(Debug, Clone)] +#[derive(Debug, PartialEq, Clone)] enum ErrorKind { /// EOF was reached when looking for a value UnexpectedEof,