diff options
Diffstat (limited to 'tvix/castore/src/digests.rs')
-rw-r--r-- | tvix/castore/src/digests.rs | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/tvix/castore/src/digests.rs b/tvix/castore/src/digests.rs index a9e810aac5dd..137ed2669a8f 100644 --- a/tvix/castore/src/digests.rs +++ b/tvix/castore/src/digests.rs @@ -15,9 +15,8 @@ pub enum Error { pub const B3_LEN: usize = 32; impl B3Digest { - // returns a copy of the inner [Vec<u8>]. - pub fn to_vec(&self) -> Vec<u8> { - self.0.to_vec() + pub fn as_slice(&self) -> &[u8] { + &self.0[..] } } |