about summary refs log tree commit diff
path: root/tvix/eval
diff options
context:
space:
mode:
Diffstat (limited to 'tvix/eval')
-rw-r--r--tvix/eval/src/vm.rs5
1 files changed, 4 insertions, 1 deletions
diff --git a/tvix/eval/src/vm.rs b/tvix/eval/src/vm.rs
index 5b6536e98664..23d9c3555153 100644
--- a/tvix/eval/src/vm.rs
+++ b/tvix/eval/src/vm.rs
@@ -323,7 +323,10 @@ impl VM {
                     self.push(self.stack[idx].clone());
                 }
 
-                OpCode::OpPushWith(StackIdx(idx)) => self.with_stack.push(idx),
+                OpCode::OpPushWith(StackIdx(idx)) => {
+                    self.with_stack.push(self.frame().stack_offset + idx)
+                }
+
                 OpCode::OpPopWith => {
                     self.with_stack.pop();
                 }