From f4a6fec2d8f73be3148641796983bceabff7ec79 Mon Sep 17 00:00:00 2001 From: Deirdre Connolly Date: Thu, 26 Sep 2019 22:34:47 -0400 Subject: [PATCH] Comment out EquihashSolution::fmt for now --- zebra-chain/src/equihash_solution.rs | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/zebra-chain/src/equihash_solution.rs b/zebra-chain/src/equihash_solution.rs index abdd2121..e0107619 100644 --- a/zebra-chain/src/equihash_solution.rs +++ b/zebra-chain/src/equihash_solution.rs @@ -1,11 +1,11 @@ //! Equihash Solution and related items. -use std::fmt; +// use std::fmt; -use hex::ToHex; +// use hex::ToHex; /// The size of an Equihash solution in bytes (always 1344). -const EQUIHASH_SOLUTION_SIZE = 1344; +const EQUIHASH_SOLUTION_SIZE: usize = 1344; /// Equihash Solution. /// @@ -24,8 +24,15 @@ impl Default for EquihashSolution { } } -impl fmt::Debug for EquihashSolution { - fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { - f.write_str(&self.0.encode_hex::()) +// TODO: fix hex crate import conflict with tracing-subscriber +// impl fmt::Debug for EquihashSolution { +// fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { +// f.write_str(&self.0.encode_hex::()) +// } +// } + +impl PartialEq for EquihashSolution { + fn eq(&self, other: &EquihashSolution) -> bool { + self.0.as_ref() == other.0.as_ref() } }