99#define yieldable(L) (((L)->nCcalls & 0xffff0000) == 0)
102#define getCcalls(L) ((L)->nCcalls & 0xffff)
106#define incnny(L) ((L)->nCcalls += 0x10000)
109#define decnny(L) ((L)->nCcalls -= 0x10000)
112#define nyci (0x10000 | 1)
124#if !defined(l_signalT)
126#define l_signalT sig_atomic_t
140#define BASIC_STACK_SIZE (2*LUA_MINSTACK)
142#define stacksize(th) cast_int((th)->stack_last - (th)->stack)
205#define CIST_OAH (1<<0)
207#define CIST_FRESH (1<<2)
208#define CIST_HOOKED (1<<3)
209#define CIST_YPCALL (1<<4)
210#define CIST_TAIL (1<<5)
211#define CIST_HOOKYIELD (1<<6)
212#define CIST_FIN (1<<7)
213#define CIST_TRAN (1<<8)
214#define CIST_CLSRET (1<<9)
217#if defined(LUA_COMPAT_LT_LE)
218#define CIST_LEQ (1<<13)
228#define getcistrecst(ci) (((ci)->callstatus >> CIST_RECST) & 7)
229#define setcistrecst(ci,st) \
230 check_exp(((st) & 7) == (st), \
231 ((ci)->callstatus = ((ci)->callstatus & ~(7 << CIST_RECST)) \
232 | ((st) << CIST_RECST)))
236#define isLua(ci) (!((ci)->callstatus & CIST_C))
239#define isLuacode(ci) (!((ci)->callstatus & (CIST_C | CIST_HOOKED)))
242#define setoah(st,v) ((st) = ((st) & ~CIST_OAH) | (v))
243#define getoah(st) ((st) & CIST_OAH)
336#define completestate(g) ttisnil(&g->nilvalue)
365#define cast_u(o) cast(union GCUnion *, (o))
369 check_exp(novariant((o)->tt) == LUA_TSTRING, &((cast_u(o))->ts))
370#define gco2u(o) check_exp((o)->tt == LUA_VUSERDATA, &((cast_u(o))->u))
371#define gco2lcl(o) check_exp((o)->tt == LUA_VLCL, &((cast_u(o))->cl.l))
372#define gco2ccl(o) check_exp((o)->tt == LUA_VCCL, &((cast_u(o))->cl.c))
374 check_exp(novariant((o)->tt) == LUA_TFUNCTION, &((cast_u(o))->cl))
375#define gco2t(o) check_exp((o)->tt == LUA_VTABLE, &((cast_u(o))->h))
376#define gco2p(o) check_exp((o)->tt == LUA_VPROTO, &((cast_u(o))->p))
377#define gco2th(o) check_exp((o)->tt == LUA_VTHREAD, &((cast_u(o))->th))
378#define gco2upv(o) check_exp((o)->tt == LUA_VUPVAL, &((cast_u(o))->upv))
385#define obj2gco(v) check_exp((v)->tt >= LUA_TSTRING, &(cast_u(v)->gc))
389#define gettotalbytes(g) cast(lu_mem, (g)->totalbytes + (g)->GCdebt)
void *(* lua_Alloc)(void *ud, void *ptr, size_t osize, size_t nsize)
int(* lua_CFunction)(lua_State *L)
void(* lua_Hook)(lua_State *L, lua_Debug *ar)
LUA_KCONTEXT lua_KContext
int(* lua_KFunction)(lua_State *L, int status, lua_KContext ctx)
LUAI_FUNC void luaE_freethread(lua_State *L, lua_State *L1)
LUAI_FUNC void luaE_warnerror(lua_State *L, const char *where)
struct stringtable stringtable
LUAI_FUNC void luaE_warning(lua_State *L, const char *msg, int tocont)
LUAI_FUNC void luaE_checkcstack(lua_State *L)
struct global_State global_State
LUAI_FUNC void luaE_shrinkCI(lua_State *L)
LUAI_FUNC CallInfo * luaE_extendCI(lua_State *L)
LUAI_FUNC int luaE_resetthread(lua_State *L, int status)
LUAI_FUNC void luaE_incCstack(lua_State *L)
LUAI_FUNC void luaE_setdebt(global_State *g, l_mem debt)
LUAI_FUNC void luaE_freeCI(lua_State *L)
void(* lua_WarnFunction)(void *ud, const char *msg, int tocont)
struct CallInfo * previous
struct CallInfo::@95::@98 transferinfo
struct CallInfo::@64::@65 l
const Instruction * savedpc
struct CallInfo::@64::@66 c
TString * strcache[STRCACHE_N][STRCACHE_M]
struct lua_State * mainthread
struct Table * mt[NUM_TAGS]
volatile l_signalT hookmask
struct lua_longjmp * errorJmp