diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2017-09-28 13:53:29 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2017-09-28 13:53:29 -0300 |
commit | 722bdbe17d0192baf72978f88069d12a921e9bfb (patch) | |
tree | 78da619d4799721e67a760bf4220b568f636cb86 /lcode.h | |
parent | 1b100335839e13021b4731f0407b87e4f7544dc0 (diff) | |
download | lua-722bdbe17d0192baf72978f88069d12a921e9bfb.tar.gz lua-722bdbe17d0192baf72978f88069d12a921e9bfb.tar.bz2 lua-722bdbe17d0192baf72978f88069d12a921e9bfb.zip |
no more 'getBMode'-'getCMode' (imprecise + we will need more space
for op mode) + better control of op modes
Diffstat (limited to 'lcode.h')
-rw-r--r-- | lcode.h | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: lcode.h,v 1.65 2017/04/20 19:53:55 roberto Exp roberto $ | 2 | ** $Id: lcode.h,v 1.66 2017/09/13 19:50:08 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 | */ |
@@ -43,13 +43,13 @@ typedef enum UnOpr { OPR_MINUS, OPR_BNOT, OPR_NOT, OPR_LEN, OPR_NOUNOPR } UnOpr; | |||
43 | /* get (pointer to) instruction of given 'expdesc' */ | 43 | /* get (pointer to) instruction of given 'expdesc' */ |
44 | #define getinstruction(fs,e) ((fs)->f->code[(e)->u.info]) | 44 | #define getinstruction(fs,e) ((fs)->f->code[(e)->u.info]) |
45 | 45 | ||
46 | #define luaK_codeAsBx(fs,o,A,sBx) luaK_codeABx(fs,o,A,(sBx)+MAXARG_sBx) | ||
47 | 46 | ||
48 | #define luaK_setmultret(fs,e) luaK_setreturns(fs, e, LUA_MULTRET) | 47 | #define luaK_setmultret(fs,e) luaK_setreturns(fs, e, LUA_MULTRET) |
49 | 48 | ||
50 | #define luaK_jumpto(fs,t) luaK_patchlist(fs, luaK_jump(fs), t) | 49 | #define luaK_jumpto(fs,t) luaK_patchlist(fs, luaK_jump(fs), t) |
51 | 50 | ||
52 | LUAI_FUNC int luaK_codeABx (FuncState *fs, OpCode o, int A, unsigned int Bx); | 51 | LUAI_FUNC int luaK_codeABx (FuncState *fs, OpCode o, int A, unsigned int Bx); |
52 | LUAI_FUNC int luaK_codeAsBx (FuncState *fs, OpCode o, int A, int Bx); | ||
53 | LUAI_FUNC int luaK_codeABC (FuncState *fs, OpCode o, int A, int B, int C); | 53 | LUAI_FUNC int luaK_codeABC (FuncState *fs, OpCode o, int A, int B, int C); |
54 | LUAI_FUNC void luaK_fixline (FuncState *fs, int line); | 54 | LUAI_FUNC void luaK_fixline (FuncState *fs, int line); |
55 | LUAI_FUNC void luaK_nil (FuncState *fs, int from, int n); | 55 | LUAI_FUNC void luaK_nil (FuncState *fs, int from, int n); |