aboutsummaryrefslogtreecommitdiff
path: root/ldebug.c
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2004-09-01 10:47:31 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2004-09-01 10:47:31 -0300
commit2aba14b623c512f759291aeadc6309346ad93974 (patch)
tree53d2baecf0a82584268556bc4fd64d95c446e876 /ldebug.c
parent1dd8c9b6b6db5500b68a11e097c67e7a39c4f53d (diff)
downloadlua-2aba14b623c512f759291aeadc6309346ad93974.tar.gz
lua-2aba14b623c512f759291aeadc6309346ad93974.tar.bz2
lua-2aba14b623c512f759291aeadc6309346ad93974.zip
details
Diffstat (limited to 'ldebug.c')
-rw-r--r--ldebug.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/ldebug.c b/ldebug.c
index eea8669f..6980cdd2 100644
--- a/ldebug.c
+++ b/ldebug.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: ldebug.c,v 2.6 2004/06/02 19:07:55 roberto Exp roberto $ 2** $Id: ldebug.c,v 2.7 2004/06/29 18:49:02 roberto Exp roberto $
3** Debug Interface 3** Debug Interface
4** See Copyright Notice in lua.h 4** See Copyright Notice in lua.h
5*/ 5*/
@@ -357,7 +357,7 @@ static Instruction luaG_symbexec (const Proto *pt, int lastpc, int reg) {
357 } 357 }
358 case OP_TFORLOOP: { 358 case OP_TFORLOOP: {
359 checkreg(pt, a+5); /* space for control variables */ 359 checkreg(pt, a+5); /* space for control variables */
360 if (reg >= a) last = pc; /* affect all registers above base */ 360 if (reg >= a+3) last = pc; /* affect all regs above its call base */
361 break; 361 break;
362 } 362 }
363 case OP_TFORPREP: 363 case OP_TFORPREP:
@@ -491,7 +491,8 @@ static const char *getfuncname (CallInfo *ci, const char **name) {
491 return NULL; /* calling function is not Lua (or is unknown) */ 491 return NULL; /* calling function is not Lua (or is unknown) */
492 ci--; /* calling function */ 492 ci--; /* calling function */
493 i = ci_func(ci)->l.p->code[currentpc(ci)]; 493 i = ci_func(ci)->l.p->code[currentpc(ci)];
494 if (GET_OPCODE(i) == OP_CALL || GET_OPCODE(i) == OP_TAILCALL) 494 if (GET_OPCODE(i) == OP_CALL || GET_OPCODE(i) == OP_TAILCALL ||
495 GET_OPCODE(i) == OP_TFORLOOP)
495 return getobjname(ci, GETARG_A(i), name); 496 return getobjname(ci, GETARG_A(i), name);
496 else 497 else
497 return NULL; /* no useful name can be found */ 498 return NULL; /* no useful name can be found */