about summary refs log tree commit diff
path: root/tvix/glue/src/builtins/mod.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tvix/glue/src/builtins/mod.rs')
-rw-r--r--tvix/glue/src/builtins/mod.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/tvix/glue/src/builtins/mod.rs b/tvix/glue/src/builtins/mod.rs
index 78e5fe87ec4c..a62ba192871f 100644
--- a/tvix/glue/src/builtins/mod.rs
+++ b/tvix/glue/src/builtins/mod.rs
@@ -20,7 +20,7 @@ pub use derivation_error::Error as DerivationError;
 /// `known_paths`.
 pub fn add_derivation_builtins<IO>(eval: &mut tvix_eval::Evaluation<IO>, io: Rc<TvixStoreIO>) {
     eval.builtins
-        .extend(derivation::derivation_builtins::builtins(io));
+        .extend(derivation::derivation_builtins::builtins(Rc::clone(&io)));
 
     // Add the actual `builtins.derivation` from compiled Nix code
     eval.src_builtins
@@ -34,7 +34,7 @@ pub fn add_derivation_builtins<IO>(eval: &mut tvix_eval::Evaluation<IO>, io: Rc<
 /// * `fetchGit`
 pub fn add_fetcher_builtins<IO>(eval: &mut tvix_eval::Evaluation<IO>, io: Rc<TvixStoreIO>) {
     eval.builtins
-        .extend(fetchers::fetcher_builtins::builtins(io));
+        .extend(fetchers::fetcher_builtins::builtins(Rc::clone(&io)));
 }
 
 /// Adds import-related builtins to the passed [tvix_eval::Evaluation].
@@ -82,8 +82,8 @@ mod tests {
 
         let mut eval = tvix_eval::Evaluation::new(io.clone() as Rc<dyn EvalIO>, false);
 
-        add_derivation_builtins(&mut eval, io.clone());
-        add_fetcher_builtins(&mut eval, io.clone());
+        add_derivation_builtins(&mut eval, Rc::clone(&io));
+        add_fetcher_builtins(&mut eval, Rc::clone(&io));
         add_import_builtins(&mut eval, io);
 
         // run the evaluation itself.