Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions serialize/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -268,14 +268,14 @@ pub trait CanonicalSerializeHashExt: CanonicalSerialize {
fn hash<H: Digest>(&self) -> Output<H> {
let mut hasher = H::new();
self.serialize_compressed(HashMarshaller(&mut hasher))
.expect("HashMarshaller::flush should be infaillible!");
.expect("HashMarshaller::flush should be infallible!");
hasher.finalize()
}

fn hash_uncompressed<H: Digest>(&self) -> Output<H> {
let mut hasher = H::new();
self.serialize_uncompressed(HashMarshaller(&mut hasher))
.expect("HashMarshaller::flush should be infaillible!");
.expect("HashMarshaller::flush should be infallible!");
hasher.finalize()
}
}
Expand Down
Loading