about summary refs log tree commit diff
path: root/tvix/eval/src/vm.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tvix/eval/src/vm.rs')
-rw-r--r--tvix/eval/src/vm.rs9
1 files changed, 8 insertions, 1 deletions
diff --git a/tvix/eval/src/vm.rs b/tvix/eval/src/vm.rs
index 1c7772f2a7e0..5ebc95e7f15e 100644
--- a/tvix/eval/src/vm.rs
+++ b/tvix/eval/src/vm.rs
@@ -357,7 +357,7 @@ impl VM {
                 OpCode::OpCall => {
                     let callable = self.pop();
                     match callable {
-                        Value::Closure(Closure { lambda }) => self.call(lambda, 1),
+                        Value::Closure(Closure { lambda, .. }) => self.call(lambda, 1),
                         Value::Builtin(builtin) => {
                             let arg = self.pop();
                             let result = builtin.apply(arg)?;
@@ -368,6 +368,13 @@ impl VM {
                 }
 
                 OpCode::OpGetUpvalue(_) => todo!("getting upvalues"),
+                OpCode::OpClosure(_) => todo!("creating closure objects"),
+
+                // Data-carrying operands should never be executed,
+                // that is a critical error in the VM.
+                OpCode::DataLocalIdx(_) | OpCode::DataUpvalueIdx(_) => {
+                    panic!("VM bug: attempted to execute data-carrying operand")
+                }
             }
 
             #[cfg(feature = "disassembler")]