Browse Source

Consuming iterator for RpoDigest

km/mkdocs-impl
Philippe Laferriere 1 year ago
committed by Bobbin Threadbare
parent
commit
fd480f827a
1 changed files with 11 additions and 0 deletions
  1. +11
    -0
      src/hash/rescue/rpo/digest.rs

+ 11
- 0
src/hash/rescue/rpo/digest.rs

@ -302,6 +302,17 @@ impl Deserializable for RpoDigest {
} }
} }
// ITERATORS
// ================================================================================================
impl IntoIterator for RpoDigest {
type Item = Felt;
type IntoIter = <[Felt; 4] as IntoIterator>::IntoIter;
fn into_iter(self) -> Self::IntoIter {
self.0.into_iter()
}
}
// TESTS // TESTS
// ================================================================================================ // ================================================================================================

Loading…
Cancel
Save