mirror of
https://github.com/lua/lua
synced 2024-11-26 06:39:41 +03:00
name changes + new operation - old operation
This commit is contained in:
parent
42130ed712
commit
14251c5a56
18
lopcodes.h
18
lopcodes.h
@ -1,5 +1,5 @@
|
||||
/*
|
||||
** $Id: lopcodes.h,v 1.53 2000/03/27 14:31:12 roberto Exp roberto $
|
||||
** $Id: lopcodes.h,v 1.54 2000/04/04 20:48:44 roberto Exp roberto $
|
||||
** Opcodes for Lua virtual machine
|
||||
** See Copyright Notice in lua.h
|
||||
*/
|
||||
@ -105,35 +105,35 @@ OP_PUSHNEGNUM,/* N - -KNUM[u] */
|
||||
|
||||
OP_PUSHUPVALUE,/* U - Closure[u] */
|
||||
|
||||
OP_PUSHLOCAL,/* L - LOC[u] */
|
||||
OP_GETLOCAL,/* L - LOC[u] */
|
||||
OP_GETGLOBAL,/* K - VAR[KSTR[k]] */
|
||||
|
||||
OP_GETTABLE,/* - i t t[i] */
|
||||
OP_GETDOTTED,/* K t t[KSTR[k]] */
|
||||
OP_GETINDEXED,/* L t t[LOC[U]] */
|
||||
OP_PUSHSELF,/* K t t t[KSTR[k]] */
|
||||
|
||||
OP_CREATETABLE,/* U - newarray(size = u) */
|
||||
|
||||
OP_SETLOCAL,/* L x - LOC[u]=x */
|
||||
OP_SETLOCAL,/* L B v_b-v_1 - LOC[L]=v_b */
|
||||
OP_SETGLOBAL,/* K x - VAR[KSTR[k]]=x */
|
||||
OP_SETTABLEPOP,/* - v i t - t[i]=v */
|
||||
OP_SETTABLE,/* U v a_u-a_1 i t a_u-a_1 i t t[i]=v */
|
||||
OP_SETTABLE,/* A B v a_a-a_1 i t a_x-a_1 i t t[i]=v */
|
||||
|
||||
OP_SETLIST,/* A B v_b-v_0 t t t[i+a*FPF]=v_i */
|
||||
OP_SETMAP,/* U v_u k_u - v_0 k_0 t t t[k_i]=v_i */
|
||||
|
||||
OP_INCLOCAL,/* sA B - - LOC[B]+=sA */
|
||||
OP_INCLOCAL,/* sA L - - LOC[L]+=sA */
|
||||
OP_ADD,/* - y x x+y */
|
||||
OP_ADDI,/* S x x+s */
|
||||
OP_SUB,/* - y x x-y */
|
||||
OP_MULT,/* - y x x*y */
|
||||
OP_DIV,/* - y x x/y */
|
||||
OP_POW,/* - y x x^y */
|
||||
OP_CONC,/* U v_u-v_1 v1..-..v_u */
|
||||
OP_CONCAT,/* U v_u-v_1 v1..-..v_u */
|
||||
OP_MINUS,/* - x -x */
|
||||
OP_NOT,/* - x (x==nil)? 1 : nil */
|
||||
|
||||
OP_JMPNEQ,/* J y x - (x~=y)? PC+=s */
|
||||
OP_JMPNE,/* J y x - (x~=y)? PC+=s */
|
||||
OP_JMPEQ,/* J y x - (x==y)? PC+=s */
|
||||
OP_JMPLT,/* J y x - (x<y)? PC+=s */
|
||||
OP_JMPLE,/* J y x - (x<y)? PC+=s */
|
||||
@ -156,7 +156,7 @@ OP_SETLINE/* U - - LINE=u */
|
||||
|
||||
|
||||
|
||||
#define ISJUMP(o) (OP_JMPNEQ <= (o) && (o) <= OP_JMP)
|
||||
#define ISJUMP(o) (OP_JMPNE <= (o) && (o) <= OP_JMP)
|
||||
|
||||
|
||||
#endif
|
||||
|
14
ltests.c
14
ltests.c
@ -1,5 +1,5 @@
|
||||
/*
|
||||
** $Id: ltests.c,v 1.10 2000/03/16 20:35:07 roberto Exp roberto $
|
||||
** $Id: ltests.c,v 1.11 2000/04/06 17:35:23 roberto Exp roberto $
|
||||
** Internal Module for Debugging of the Lua Implementation
|
||||
** See Copyright Notice in lua.h
|
||||
*/
|
||||
@ -70,16 +70,16 @@ static int printop (lua_State *L, Instruction i) {
|
||||
case OP_PUSHNUM: U("PUSHNUM"); break;
|
||||
case OP_PUSHNEGNUM: U("PUSHNEGNUM"); break;
|
||||
case OP_PUSHUPVALUE: U("PUSHUPVALUE"); break;
|
||||
case OP_PUSHLOCAL: U("PUSHLOCAL"); break;
|
||||
case OP_GETLOCAL: U("GETLOCAL"); break;
|
||||
case OP_GETGLOBAL: U("GETGLOBAL"); break;
|
||||
case OP_GETTABLE: O("GETTABLE"); break;
|
||||
case OP_GETDOTTED: U("GETDOTTED"); break;
|
||||
case OP_GETINDEXED: U("GETINDEXED"); break;
|
||||
case OP_PUSHSELF: U("PUSHSELF"); break;
|
||||
case OP_CREATETABLE: U("CREATETABLE"); break;
|
||||
case OP_SETLOCAL: U("SETLOCAL"); break;
|
||||
case OP_SETLOCAL: AB("SETLOCAL"); break;
|
||||
case OP_SETGLOBAL: U("SETGLOBAL"); break;
|
||||
case OP_SETTABLEPOP: O("SETTABLEPOP"); break;
|
||||
case OP_SETTABLE: U("SETTABLE"); break;
|
||||
case OP_SETTABLE: AB("SETTABLE"); break;
|
||||
case OP_SETLIST: AB("SETLIST"); break;
|
||||
case OP_SETMAP: U("SETMAP"); break;
|
||||
case OP_ADD: O("ADD"); break;
|
||||
@ -89,10 +89,10 @@ static int printop (lua_State *L, Instruction i) {
|
||||
case OP_MULT: O("MULT"); break;
|
||||
case OP_DIV: O("DIV"); break;
|
||||
case OP_POW: O("POW"); break;
|
||||
case OP_CONC: U("CONC"); break;
|
||||
case OP_CONCAT: U("CONCAT"); break;
|
||||
case OP_MINUS: O("MINUS"); break;
|
||||
case OP_NOT: O("NOT"); break;
|
||||
case OP_JMPNEQ: S("JMPNEQ"); break;
|
||||
case OP_JMPNE: S("JMPNE"); break;
|
||||
case OP_JMPEQ: S("JMPEQ"); break;
|
||||
case OP_JMPLT: S("JMPLT"); break;
|
||||
case OP_JMPLE: S("JMPLE"); break;
|
||||
|
Loading…
Reference in New Issue
Block a user