aboutsummaryrefslogtreecommitdiff
path: root/lcode.c
diff options
context:
space:
mode:
Diffstat (limited to 'lcode.c')
-rw-r--r--lcode.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/lcode.c b/lcode.c
index 68b1bfe2..c54ae525 100644
--- a/lcode.c
+++ b/lcode.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: lcode.c,v 2.26 2006/06/22 16:12:59 roberto Exp roberto $ 2** $Id: lcode.c,v 2.27 2006/08/07 19:14:30 roberto Exp roberto $
3** Code generator for Lua 3** Code generator for Lua
4** See Copyright Notice in lua.h 4** See Copyright Notice in lua.h
5*/ 5*/
@@ -235,8 +235,7 @@ static int addk (FuncState *fs, TValue *key, TValue *v) {
235 int oldsize = f->sizek; 235 int oldsize = f->sizek;
236 k = fs->nk; 236 k = fs->nk;
237 setnvalue(idx, cast_num(k)); 237 setnvalue(idx, cast_num(k));
238 luaM_growvector(L, f->k, k, f->sizek, TValue, MAXARG_Bx, 238 luaM_growvector(L, f->k, k, f->sizek, TValue, MAXARG_Bx, "constant table");
239 "constant table overflow");
240 while (oldsize < f->sizek) setnilvalue(&f->k[oldsize++]); 239 while (oldsize < f->sizek) setnilvalue(&f->k[oldsize++]);
241 setobj(L, &f->k[k], v); 240 setobj(L, &f->k[k], v);
242 fs->nk++; 241 fs->nk++;
@@ -787,11 +786,11 @@ static int luaK_code (FuncState *fs, Instruction i, int line) {
787 dischargejpc(fs); /* `pc' will change */ 786 dischargejpc(fs); /* `pc' will change */
788 /* put new instruction in code array */ 787 /* put new instruction in code array */
789 luaM_growvector(fs->L, f->code, fs->pc, f->sizecode, Instruction, 788 luaM_growvector(fs->L, f->code, fs->pc, f->sizecode, Instruction,
790 MAX_INT, "code size overflow"); 789 MAX_INT, "code size");
791 f->code[fs->pc] = i; 790 f->code[fs->pc] = i;
792 /* save corresponding line information */ 791 /* save corresponding line information */
793 luaM_growvector(fs->L, f->lineinfo, fs->pc, f->sizelineinfo, int, 792 luaM_growvector(fs->L, f->lineinfo, fs->pc, f->sizelineinfo, int,
794 MAX_INT, "code size overflow"); 793 MAX_INT, "code size");
795 f->lineinfo[fs->pc] = line; 794 f->lineinfo[fs->pc] = line;
796 return fs->pc++; 795 return fs->pc++;
797} 796}