diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2000-08-14 14:46:27 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2000-08-14 14:46:27 -0300 |
commit | 58453dc1e1cb8c77f91cb858ec9b475a945f7f3c (patch) | |
tree | 0ad99964acf87f941b318f6edbe9413b71b7e8b6 /lcode.c | |
parent | f555e493f0a12513f79f999ceed5467085b1c9c4 (diff) | |
download | lua-58453dc1e1cb8c77f91cb858ec9b475a945f7f3c.tar.gz lua-58453dc1e1cb8c77f91cb858ec9b475a945f7f3c.tar.bz2 lua-58453dc1e1cb8c77f91cb858ec9b475a945f7f3c.zip |
small bug in symbolic execution
Diffstat (limited to 'lcode.c')
-rw-r--r-- | lcode.c | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: lcode.c,v 1.46 2000/08/09 19:16:57 roberto Exp roberto $ | 2 | ** $Id: lcode.c,v 1.47 2000/08/10 19:50:47 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 | */ |
@@ -330,7 +330,8 @@ void luaK_tostack (LexState *ls, expdesc *v, int onlyone) { | |||
330 | luaK_concat(fs, &v->u.l.t, fs->pc-1); /* put `previous' in t. list */ | 330 | luaK_concat(fs, &v->u.l.t, fs->pc-1); /* put `previous' in t. list */ |
331 | else { | 331 | else { |
332 | j = code_label(fs, OP_JMP, NO_JUMP); /* to jump over both pushes */ | 332 | j = code_label(fs, OP_JMP, NO_JUMP); /* to jump over both pushes */ |
333 | luaK_deltastack(fs, -1); /* next PUSHes may be skipped */ | 333 | /* correct stack for compiler and simbolic execution */ |
334 | luaK_adjuststack(fs, 1); | ||
334 | } | 335 | } |
335 | p_nil = code_label(fs, OP_PUSHNILJMP, 0); | 336 | p_nil = code_label(fs, OP_PUSHNILJMP, 0); |
336 | p_1 = code_label(fs, OP_PUSHINT, 1); | 337 | p_1 = code_label(fs, OP_PUSHINT, 1); |