summaryrefslogtreecommitdiff
path: root/cli/cache
diff options
context:
space:
mode:
Diffstat (limited to 'cli/cache')
-rw-r--r--cli/cache/common.rs8
1 files changed, 8 insertions, 0 deletions
diff --git a/cli/cache/common.rs b/cli/cache/common.rs
index d1578ce8d..94fe383a5 100644
--- a/cli/cache/common.rs
+++ b/cli/cache/common.rs
@@ -34,6 +34,14 @@ impl FastInsecureHasher {
self
}
+ pub fn write_hashable(
+ &mut self,
+ hashable: &impl std::hash::Hash,
+ ) -> &mut Self {
+ hashable.hash(&mut self.0);
+ self
+ }
+
pub fn finish(&self) -> u64 {
self.0.finish()
}