diff --git a/implementations/rust/src/value/value.rs b/implementations/rust/src/value/value.rs index 3013d7a..40bb83c 100644 --- a/implementations/rust/src/value/value.rs +++ b/implementations/rust/src/value/value.rs @@ -693,7 +693,7 @@ impl<'de> serde::Deserialize<'de> for PlainValue { use std::rc::Rc; -#[derive(Clone, PartialEq, Eq, PartialOrd, Ord)] +#[derive(Clone, PartialEq, Eq, Hash, PartialOrd, Ord)] pub struct RcValue(Rc>); impl NestedValue for RcValue { @@ -728,12 +728,6 @@ impl NestedValue for RcValue { } } -impl Hash for RcValue { - fn hash(&self, state: &mut H) { - (self.0).1.hash(state) - } -} - impl Debug for RcValue { fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { self.debug_fmt(f) @@ -756,7 +750,7 @@ impl<'de> serde::Deserialize<'de> for RcValue { use std::sync::Arc; -#[derive(Clone, PartialEq, Eq, PartialOrd, Ord)] +#[derive(Clone, PartialEq, Eq, Hash, PartialOrd, Ord)] pub struct ArcValue(Arc>); impl NestedValue for ArcValue { @@ -791,12 +785,6 @@ impl NestedValue for ArcValue { } } -impl Hash for ArcValue { - fn hash(&self, state: &mut H) { - (self.0).1.hash(state) - } -} - impl Debug for ArcValue { fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { self.debug_fmt(f)