about summary refs log tree commit diff
path: root/tvix/eval/src/eval.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tvix/eval/src/eval.rs')
-rw-r--r--tvix/eval/src/eval.rs6
1 files changed, 4 insertions, 2 deletions
diff --git a/tvix/eval/src/eval.rs b/tvix/eval/src/eval.rs
index 31280e4cd197..903708f108b3 100644
--- a/tvix/eval/src/eval.rs
+++ b/tvix/eval/src/eval.rs
@@ -1,8 +1,10 @@
+use std::path::PathBuf;
+
 use rnix::{self, types::TypedNode};
 
 use crate::{errors::EvalResult, value::Value};
 
-pub fn interpret(code: &str) -> EvalResult<Value> {
+pub fn interpret(code: &str, location: Option<PathBuf>) -> EvalResult<Value> {
     let ast = rnix::parse(code);
 
     let errors = ast.errors();
@@ -14,7 +16,7 @@ pub fn interpret(code: &str) -> EvalResult<Value> {
         println!("{}", ast.root().dump());
     }
 
-    let result = crate::compiler::compile(ast)?;
+    let result = crate::compiler::compile(ast, location)?;
     println!("code: {:?}", result.chunk);
 
     for warning in result.warnings {