diff options
-rw-r--r-- | tvix/nix-compat/src/derivation/write.rs | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/tvix/nix-compat/src/derivation/write.rs b/tvix/nix-compat/src/derivation/write.rs index 5937f619b719..d84992a3cbc4 100644 --- a/tvix/nix-compat/src/derivation/write.rs +++ b/tvix/nix-compat/src/derivation/write.rs @@ -126,8 +126,8 @@ pub fn write_input_derivations( writer, &input_derivation .iter() - .map(|s| s.as_bytes().to_vec().into()) - .collect::<Vec<BString>>(), + .map(String::as_bytes) + .collect::<Vec<_>>(), )?; write_char(writer, BRACKET_CLOSE)?; @@ -146,10 +146,7 @@ pub fn write_input_sources( write_char(writer, BRACKET_OPEN)?; write_array_elements( writer, - &input_sources - .iter() - .map(|s| s.as_bytes().to_vec().into()) - .collect::<Vec<BString>>(), + &input_sources.iter().map(String::from).collect::<Vec<_>>(), )?; write_char(writer, BRACKET_CLOSE)?; |