Update of /cvsroot/wxlua/wxLua/modules/lua/src
In directory sc8-pr-cvs9.sourceforge.net:/tmp/cvs-serv29720/modules/lua/src
Modified Files:
ldebug.c lparser.c
Log Message:
apply lua 5.1.1 patches, List constructors have wrong limit. and Wrong message error closeures
Index: ldebug.c
===================================================================
RCS file: /cvsroot/wxlua/wxLua/modules/lua/src/ldebug.c,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** ldebug.c 29 Mar 2006 05:48:11 -0000 1.2
--- ldebug.c 22 Sep 2006 19:39:59 -0000 1.3
***************
*** 185,189 ****
for (i=0; i<f->l.p->sizelineinfo; i++)
setbvalue(luaH_setnum(L, t, lineinfo[i]), 1);
! sethvalue(L, L->top, t);
}
incr_top(L);
--- 185,189 ----
for (i=0; i<f->l.p->sizelineinfo; i++)
setbvalue(luaH_setnum(L, t, lineinfo[i]), 1);
! sethvalue(L, L->top, t);
}
incr_top(L);
***************
*** 433,445 ****
}
case OP_CLOSURE: {
! int nup;
check(b < pt->sizep);
nup = pt->p[b]->nups;
check(pc + nup < pt->sizecode);
! for (; nup>0; nup--) {
! OpCode op1 = GET_OPCODE(pt->code[pc+nup]);
! check(op1 == OP_GETUPVAL || op1 == OP_MOVE);
! }
! break;
}
case OP_VARARG: {
--- 433,447 ----
}
case OP_CLOSURE: {
! int nup, j;
check(b < pt->sizep);
nup = pt->p[b]->nups;
check(pc + nup < pt->sizecode);
! for (j = 1; j <= nup; j++) {
! OpCode op1 = GET_OPCODE(pt->code[pc + j]);
! check(op1 == OP_GETUPVAL || op1 == OP_MOVE);
! }
! if (reg != NO_REG) /* tracing? */
! pc += nup; /* do not 'execute' these pseudo-instructions */
! break;
}
case OP_VARARG: {
Index: lparser.c
===================================================================
RCS file: /cvsroot/wxlua/wxLua/modules/lua/src/lparser.c,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** lparser.c 12 Jun 2006 03:50:37 -0000 1.3
--- lparser.c 22 Sep 2006 19:39:59 -0000 1.4
***************
*** 490,494 ****
static void listfield (LexState *ls, struct ConsControl *cc) {
expr(ls, &cc->v);
! luaY_checklimit(ls->fs, cc->na, MAXARG_Bx, "items in a constructor");
cc->na++;
cc->tostore++;
--- 490,494 ----
static void listfield (LexState *ls, struct ConsControl *cc) {
expr(ls, &cc->v);
! luaY_checklimit(ls->fs, cc->na, MAX_INT, "items in a constructor");
cc->na++;
cc->tostore++;
|