opcLdGlobal bugfix

This commit is contained in:
Araq
2013-10-16 17:26:07 +02:00
parent 3d18053370
commit ca12bf76f5

View File

@@ -652,7 +652,7 @@ proc rawExecute(c: PCtx, start: int, tos: PStackFrame): PNode =
else:
asgnComplex(regs[ra], c.constants.sons[rb])
of opcLdGlobal:
let rb = instr.regBx - wordExcess
let rb = instr.regBx - wordExcess - 1
if regs[ra].isNil:
regs[ra] = copyTree(c.globals.sons[rb])
else: