about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--tvix/eval/src/eval.rs6
1 files changed, 5 insertions, 1 deletions
diff --git a/tvix/eval/src/eval.rs b/tvix/eval/src/eval.rs
index add621af6cc3..d61e51e6afc2 100644
--- a/tvix/eval/src/eval.rs
+++ b/tvix/eval/src/eval.rs
@@ -42,7 +42,11 @@ pub fn interpret(code: &str, location: Option<PathBuf>) -> EvalResult<Value> {
     }
 
     for error in &result.errors {
-        eprintln!("compiler error: {:?} at {:?}", error.kind, error.node,);
+        eprintln!(
+            "compiler error: {:?} at {:?}",
+            error.kind,
+            error.node.as_ref().map(|node| node.text())
+        );
     }
 
     if let Some(err) = result.errors.last() {