From 2ff764ceb700a1ef18fb532fbbc1ff937ed63f8a Mon Sep 17 00:00:00 2001 From: Vincent Ambo Date: Mon, 3 Oct 2022 17:08:39 +0300 Subject: refactor(tvix/eval): remove unnecessary clones in compiler There's basically nothing that needs *ownership* of an AST node (which is just a little box full of references to other things anyways), so we can thread this through as references all the way. Change-Id: I35a1348a50c0e8e07d51dfc18847829379166fbf Reviewed-on: https://cl.tvl.fyi/c/depot/+/6853 Tested-by: BuildkiteCI Reviewed-by: grfn --- corp/tvixbolt/src/main.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'corp/tvixbolt') diff --git a/corp/tvixbolt/src/main.rs b/corp/tvixbolt/src/main.rs index ed5dada4c48c..c4b28f0fd490 100644 --- a/corp/tvixbolt/src/main.rs +++ b/corp/tvixbolt/src/main.rs @@ -254,7 +254,7 @@ fn eval(trace: bool, code: &str) -> Output { let mut compilation_observer = DisassemblingObserver::new(codemap.clone(), &mut out.bytecode); let result = tvix_eval::compile( - root_expr, + &root_expr, Some("/nixbolt".into()), file.clone(), tvix_eval::global_builtins(), -- cgit 1.4.1