Begin implementing cached hashing in types

This commit is contained in:
Paul Hauner
2019-04-26 15:24:18 +10:00
parent ecff8f0007
commit f65e981f6f
41 changed files with 590 additions and 47 deletions

View File

@@ -60,7 +60,7 @@ fn last_leaf_needs_padding(num_bytes: usize) -> bool {
}
/// Rounds up
fn num_unsanitized_leaves(num_bytes: usize) -> usize {
pub fn num_unsanitized_leaves(num_bytes: usize) -> usize {
(num_bytes + HASHSIZE - 1) / HASHSIZE
}