about summary refs log tree commit diff
path: root/tvix/eval/src/disassembler.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tvix/eval/src/disassembler.rs')
-rw-r--r--tvix/eval/src/disassembler.rs8
1 files changed, 5 insertions, 3 deletions
diff --git a/tvix/eval/src/disassembler.rs b/tvix/eval/src/disassembler.rs
index e3cc1f16e706..a555f9179102 100644
--- a/tvix/eval/src/disassembler.rs
+++ b/tvix/eval/src/disassembler.rs
@@ -15,9 +15,7 @@ pub struct Tracer(TabWriter<Stderr>);
 
 impl Tracer {
     pub fn new() -> Self {
-        let mut tw = TabWriter::new(std::io::stderr());
-        write!(&mut tw, "=== runtime trace ===\n").ok();
-        Tracer(tw)
+        Tracer(TabWriter::new(std::io::stderr()))
     }
 
     pub fn trace(&mut self, op: &OpCode, ip: usize, stack: &[Value]) {
@@ -29,6 +27,10 @@ impl Tracer {
 
         write!(&mut self.0, "]\n").ok();
     }
+
+    pub fn literal(&mut self, line: &str) {
+        let _ = write!(&mut self.0, "{}\n", line);
+    }
 }
 
 impl Drop for Tracer {