#include "lprefix.h"
#include <float.h>
#include <limits.h>
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "lua.h"
#include "ldebug.h"
#include "ldo.h"
#include "lfunc.h"
#include "lgc.h"
#include "lobject.h"
#include "lopcodes.h"
#include "lstate.h"
#include "lstring.h"
#include "ltable.h"
#include "ltm.h"
#include "lvm.h"
Go to the source code of this file.
Macros | |
#define | checkGC(L, c) |
#define | docondjump() if (cond != GETARG_k(i)) pc++; else donextjump(ci); |
#define | dojump(ci, i, e) { pc += GETARG_sJ(i) + e; updatetrap(ci); } |
#define | donextjump(ci) { Instruction ni = *pc; dojump(ci, ni, 1); } |
#define | halfProtect(exp) (savestate(L,ci), (exp)) |
#define | isemptystr(o) (ttisshrstring(o) && tsvalue(o)->shrlen == 0) |
#define | KB(i) (k+GETARG_B(i)) |
#define | KC(i) (k+GETARG_C(i)) |
#define | l_addi(L, a, b) intop(+, a, b) |
#define | l_band(a, b) intop(&, a, b) |
#define | l_bor(a, b) intop(|, a, b) |
#define | l_bxor(a, b) intop(^, a, b) |
#define | l_gei(a, b) (a >= b) |
#define | l_gti(a, b) (a > b) |
#define | l_intfitsf(i) 1 |
#define | l_lei(a, b) (a <= b) |
#define | l_lti(a, b) (a < b) |
#define | l_muli(L, a, b) intop(*, a, b) |
#define | l_subi(L, a, b) intop(-, a, b) |
#define | LUA_CORE |
#define | LUA_USE_JUMPTABLE 0 |
#define | luaV_shiftr(x, y) luaV_shiftl(x,-(y)) |
#define | lvm_c |
#define | MAXTAGLOOP 2000 |
#define | NBITS cast_int(sizeof(lua_Integer) * CHAR_BIT) |
#define | NBM (l_floatatt(MANT_DIG)) |
#define | op_arith(L, iop, fop) |
#define | op_arith_aux(L, v1, v2, iop, fop) |
#define | op_arithf(L, fop) |
#define | op_arithf_aux(L, v1, v2, fop) |
#define | op_arithfK(L, fop) |
#define | op_arithI(L, iop, fop) |
#define | op_arithK(L, iop, fop) |
#define | op_bitwise(L, op) |
#define | op_bitwiseK(L, op) |
#define | op_order(L, opi, opn, other) |
#define | op_orderI(L, opi, opf, inv, tm) |
#define | Protect(exp) (savestate(L,ci), (exp), updatetrap(ci)) |
#define | ProtectNT(exp) (savepc(L), (exp), updatetrap(ci)) |
#define | RA(i) (base+GETARG_A(i)) |
#define | RB(i) (base+GETARG_B(i)) |
#define | RC(i) (base+GETARG_C(i)) |
#define | RKC(i) ((TESTARG_k(i)) ? k + GETARG_C(i) : s2v(base + GETARG_C(i))) |
#define | savepc(L) (ci->u.l.savedpc = pc) |
#define | savestate(L, ci) (savepc(L), L->top = ci->top) |
#define | tostring(L, o) (ttisstring(o) || (cvt2str(o) && (luaO_tostring(L, o), 1))) |
#define | updatebase(ci) (base = ci->func + 1) |
#define | updatestack(ci) { if (l_unlikely(trap)) { updatebase(ci); ra = RA(i); } } |
#define | updatetrap(ci) (trap = ci->u.l.trap) |
#define | vmbreak break |
#define | vmcase(l) case l: |
#define | vmdispatch(o) switch(o) |
#define | vmfetch() |
#define | vRB(i) s2v(RB(i)) |
#define | vRC(i) s2v(RC(i)) |
#define checkGC | ( | L, | |
c | |||
) |
#define docondjump | ( | ) | if (cond != GETARG_k(i)) pc++; else donextjump(ci); |
#define dojump | ( | ci, | |
i, | |||
e | |||
) | { pc += GETARG_sJ(i) + e; updatetrap(ci); } |
#define donextjump | ( | ci | ) | { Instruction ni = *pc; dojump(ci, ni, 1); } |
#define isemptystr | ( | o | ) | (ttisshrstring(o) && tsvalue(o)->shrlen == 0) |
#define luaV_shiftr | ( | x, | |
y | |||
) | luaV_shiftl(x,-(y)) |
#define NBITS cast_int(sizeof(lua_Integer) * CHAR_BIT) |
#define NBM (l_floatatt(MANT_DIG)) |
#define op_arith | ( | L, | |
iop, | |||
fop | |||
) |
#define op_arith_aux | ( | L, | |
v1, | |||
v2, | |||
iop, | |||
fop | |||
) |
#define op_arithf | ( | L, | |
fop | |||
) |
#define op_arithf_aux | ( | L, | |
v1, | |||
v2, | |||
fop | |||
) |
#define op_arithfK | ( | L, | |
fop | |||
) |
#define op_arithI | ( | L, | |
iop, | |||
fop | |||
) |
#define op_arithK | ( | L, | |
iop, | |||
fop | |||
) |
#define op_bitwise | ( | L, | |
op | |||
) |
#define op_bitwiseK | ( | L, | |
op | |||
) |
#define op_order | ( | L, | |
opi, | |||
opn, | |||
other | |||
) |
#define op_orderI | ( | L, | |
opi, | |||
opf, | |||
inv, | |||
tm | |||
) |
#define Protect | ( | exp | ) | (savestate(L,ci), (exp), updatetrap(ci)) |
#define ProtectNT | ( | exp | ) | (savepc(L), (exp), updatetrap(ci)) |
#define tostring | ( | L, | |
o | |||
) | (ttisstring(o) || (cvt2str(o) && (luaO_tostring(L, o), 1))) |
#define updatestack | ( | ci | ) | { if (l_unlikely(trap)) { updatebase(ci); ra = RA(i); } } |
#define vmfetch | ( | ) |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
int luaV_flttointeger | ( | lua_Number | n, |
lua_Integer * | p, | ||
F2Imod | mode | ||
) |
lua_Integer luaV_idiv | ( | lua_State * | L, |
lua_Integer | m, | ||
lua_Integer | n | ||
) |
lua_Integer luaV_mod | ( | lua_State * | L, |
lua_Integer | m, | ||
lua_Integer | n | ||
) |
lua_Number luaV_modf | ( | lua_State * | L, |
lua_Number | m, | ||
lua_Number | n | ||
) |
lua_Integer luaV_shiftl | ( | lua_Integer | x, |
lua_Integer | y | ||
) |
int luaV_tointeger | ( | const TValue * | obj, |
lua_Integer * | p, | ||
F2Imod | mode | ||
) |
int luaV_tointegerns | ( | const TValue * | obj, |
lua_Integer * | p, | ||
F2Imod | mode | ||
) |
int luaV_tonumber_ | ( | const TValue * | obj, |
lua_Number * | n | ||
) |