diff options
Diffstat (limited to 'src/ldebug.js')
-rw-r--r-- | src/ldebug.js | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/src/ldebug.js b/src/ldebug.js index 532fd9c..1c55264 100644 --- a/src/ldebug.js +++ b/src/ldebug.js @@ -116,7 +116,7 @@ const findlocal = function(L, ci, n) { base = ci.funcOff + 1; if (name === null) { /* no 'standard' name? */ - let limit = ci === L.ci ? L.top : ci.next.func; + let limit = ci === L.ci ? L.top : ci.next.funcOff; if (limit - base >= n && n > 0) /* is 'n' inside 'ci' stack? */ name = defs.to_luastring("(*temporary)", true); /* generic name for any valid slot */ else @@ -475,18 +475,18 @@ const funcnamefromcode = function(L, ci) { case OCi.OP_SETTABLE: tm = ltm.TMS.TM_NEWINDEX; break; - case OCi.OP_ADD: tm = ltm.TMS.OP_ADD; break; - case OCi.OP_SUB: tm = ltm.TMS.OP_SUB; break; - case OCi.OP_MUL: tm = ltm.TMS.OP_MUL; break; - case OCi.OP_MOD: tm = ltm.TMS.OP_MOD; break; - case OCi.OP_POW: tm = ltm.TMS.OP_POW; break; - case OCi.OP_DIV: tm = ltm.TMS.OP_DIV; break; - case OCi.OP_IDIV: tm = ltm.TMS.OP_IDI; break; - case OCi.OP_BAND: tm = ltm.TMS.OP_BAN; break; - case OCi.OP_BOR: tm = ltm.TMS.OP_BOR; break; - case OCi.OP_BXOR: tm = ltm.TMS.OP_BXO; break; - case OCi.OP_SHL: tm = ltm.TMS.OP_SHL; break; - case OCi.OP_SHR: tm = ltm.TMS.OP_SHR; break; + case OCi.OP_ADD: tm = ltm.TMS.TM_ADD; break; + case OCi.OP_SUB: tm = ltm.TMS.TM_SUB; break; + case OCi.OP_MUL: tm = ltm.TMS.TM_MUL; break; + case OCi.OP_MOD: tm = ltm.TMS.TM_MOD; break; + case OCi.OP_POW: tm = ltm.TMS.TM_POW; break; + case OCi.OP_DIV: tm = ltm.TMS.TM_DIV; break; + case OCi.OP_IDIV: tm = ltm.TMS.TM_IDIV; break; + case OCi.OP_BAND: tm = ltm.TMS.TM_BAND; break; + case OCi.OP_BOR: tm = ltm.TMS.TM_BOR; break; + case OCi.OP_BXOR: tm = ltm.TMS.TM_BXOR; break; + case OCi.OP_SHL: tm = ltm.TMS.TM_SHL; break; + case OCi.OP_SHR: tm = ltm.TMS.TM_SHR; break; case OCi.OP_UNM: tm = ltm.TMS.TM_UNM; break; case OCi.OP_BNOT: tm = ltm.TMS.TM_BNOT; break; case OCi.OP_LEN: tm = ltm.TMS.TM_LEN; break; |