about summary refs log tree commit diff
path: root/tvix/nix-compat/src/store_path/mod.rs
diff options
context:
space:
mode:
authorFlorian Klink <flokli@flokli.de>2023-11-05T12·05+0200
committerflokli <flokli@flokli.de>2023-11-05T12·20+0000
commitfb7e2a247ac9e0e8b24986b126d8aa98e40706c7 (patch)
tree4725e6c7438c02641e6eee7a2f70e05c472feca4 /tvix/nix-compat/src/store_path/mod.rs
parentd660c5dec83e4eda9363bff924ebca171a49c82a (diff)
refactor(tvix/nix-compat): drop useless try_into().expect() r/6948
This already has the right type.

Change-Id: I8f5850a41f9e97f1bc5f2a45ca05cf7439665c9d
Reviewed-on: https://cl.tvl.fyi/c/depot/+/9954
Reviewed-by: raitobezarius <tvl@lahfa.xyz>
Tested-by: BuildkiteCI
Diffstat (limited to 'tvix/nix-compat/src/store_path/mod.rs')
-rw-r--r--tvix/nix-compat/src/store_path/mod.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/tvix/nix-compat/src/store_path/mod.rs b/tvix/nix-compat/src/store_path/mod.rs
index 10bf1eb0266c..8a1b3a595a09 100644
--- a/tvix/nix-compat/src/store_path/mod.rs
+++ b/tvix/nix-compat/src/store_path/mod.rs
@@ -209,7 +209,7 @@ impl<'a> StorePathRef<'a> {
         }
 
         Ok(StorePathRef {
-            digest: digest.try_into().expect("size is known"),
+            digest,
             name: validate_name(&s[ENCODED_DIGEST_SIZE + 1..])?,
         })
     }