From 02bec8525e5dbdb9de0268d666af7511bb130e64 Mon Sep 17 00:00:00 2001 From: daurnimator Date: Mon, 29 May 2017 13:42:52 +1000 Subject: src/lvm.js: Move OP_SETUPVAL into opcode order location --- src/lvm.js | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'src') diff --git a/src/lvm.js b/src/lvm.js index ce978f4..31ad74d 100644 --- a/src/lvm.js +++ b/src/lvm.js @@ -175,11 +175,6 @@ const luaV_execute = function(L) { lobject.setobj2s(L, ra, cl.upvals[b].v); break; } - case OCi.OP_SETUPVAL: { - let uv = cl.upvals[i.B]; - uv.v.setfrom(L.stack[ra]); - break; - } case OCi.OP_GETTABUP: { let upval = cl.upvals[i.B].v; let rc = RKC(L, base, k, i); @@ -199,6 +194,10 @@ const luaV_execute = function(L) { settable(L, upval, rb, rc); break; } + case OCi.OP_SETUPVAL: { + let uv = cl.upvals[i.B]; + uv.v.setfrom(L.stack[ra]); + break; } case OCi.OP_SETTABLE: { let table = L.stack[ra]; -- cgit v1.2.3-70-g09d2