From 9f45dea2c0308ebb19d2fde4cb8305facdea2d0e Mon Sep 17 00:00:00 2001 From: Luna Date: Mon, 3 Jun 2019 00:58:44 -0300 Subject: [PATCH] vm: remove uneeded hack --- src/vm.zig | 7 ------- 1 file changed, 7 deletions(-) diff --git a/src/vm.zig b/src/vm.zig index a0decdf..24a72f8 100644 --- a/src/vm.zig +++ b/src/vm.zig @@ -237,13 +237,6 @@ pub const VM = struct { fn doGetGlobal(self: *VM, name: []u8) !void { var kv_opt = self.globals.get(name); - // take out the OP_CONST loaded before, if any - // note this is a complete hack. - //var val = self.peek(0); - //if (val.vtype == .Object and val.as.Object.otype == .String and std.mem.compare(u8, val.as.Object.value.String, name) == .Equal) { - // _ = self.pop(); - //} - if (kv_opt) |kv| { try self.push(kv.value); } else {