aboutsummaryrefslogtreecommitdiff
path: root/vm.d
diff options
context:
space:
mode:
Diffstat (limited to 'vm.d')
-rw-r--r--vm.d3
1 files changed, 2 insertions, 1 deletions
diff --git a/vm.d b/vm.d
index 6fc6df7..ff2eb1d 100644
--- a/vm.d
+++ b/vm.d
@@ -223,7 +223,6 @@ class VM {
InterpretResult run() {
writeln("== VM running ==");
- writefln("> > > framecount: %d", this.frameCount);
while (true) {
if (DEBUG) {
writeln(" Stacks:");
@@ -264,6 +263,8 @@ class VM {
}
Value val = this.popA();
this.globals[asString(name)] = val;
+ Value nil = { ValueType.NIL };
+ this.pushA(nil);
break;
case OpCode.OP_GET_GLOBAL:
Value name = this.current.func.chunk.constants[this.readByte()];