diff --git a/src/interned.rs b/src/interned.rs index ba58b512..6f1c41e1 100644 --- a/src/interned.rs +++ b/src/interned.rs @@ -394,9 +394,7 @@ impl Lookup for &str { impl + Clone + Lookup, T> Lookup> for &[A] { fn hash(&self, h: &mut H) { - for a in *self { - Hash::hash(a, h); - } + Hash::hash(self, h); } fn eq(&self, data: &Vec) -> bool { @@ -410,9 +408,7 @@ impl + Clone + Lookup, T> Lookup> for &[A] impl + Clone + Lookup, T> Lookup> for [A; N] { fn hash(&self, h: &mut H) { - for a in self { - Hash::hash(a, h); - } + Hash::hash(self, h); } fn eq(&self, data: &Vec) -> bool {