58#if !defined(l_signalT)
60#define l_signalT sig_atomic_t
68#define BASIC_STACK_SIZE (2*LUA_MINSTACK)
73#define KGC_EMERGENCY 1
116#define CIST_OAH (1<<0)
117#define CIST_LUA (1<<1)
118#define CIST_HOOKED (1<<2)
119#define CIST_FRESH (1<<3)
121#define CIST_YPCALL (1<<4)
122#define CIST_TAIL (1<<5)
123#define CIST_HOOKYIELD (1<<6)
124#define CIST_LEQ (1<<7)
125#define CIST_FIN (1<<8)
127#define isLua(ci) ((ci)->callstatus & CIST_LUA)
130#define setoah(st,v) ((st) = ((st) & ~CIST_OAH) | (v))
131#define getoah(st) ((st) & CIST_OAH)
222#define cast_u(o) cast(union GCUnion *, (o))
226 check_exp(novariant((o)->tt) == LUA_TSTRING, &((cast_u(o))->ts))
227#define gco2u(o) check_exp((o)->tt == LUA_TUSERDATA, &((cast_u(o))->u))
228#define gco2lcl(o) check_exp((o)->tt == LUA_TLCL, &((cast_u(o))->cl.l))
229#define gco2ccl(o) check_exp((o)->tt == LUA_TCCL, &((cast_u(o))->cl.c))
231 check_exp(novariant((o)->tt) == LUA_TFUNCTION, &((cast_u(o))->cl))
232#define gco2t(o) check_exp((o)->tt == LUA_TTABLE, &((cast_u(o))->h))
233#define gco2p(o) check_exp((o)->tt == LUA_TPROTO, &((cast_u(o))->p))
234#define gco2th(o) check_exp((o)->tt == LUA_TTHREAD, &((cast_u(o))->th))
239 check_exp(novariant((v)->tt) < LUA_TDEADKEY, (&(cast_u(v)->gc)))
243#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)
LUAI_FUNC void luaE_freethread(lua_State *L, lua_State *L1)
struct stringtable stringtable
struct global_State global_State
LUAI_FUNC void luaE_shrinkCI(lua_State *L)
LUAI_FUNC CallInfo * luaE_extendCI(lua_State *L)
LUAI_FUNC void luaE_setdebt(global_State *g, l_mem debt)
LUAI_FUNC void luaE_freeCI(lua_State *L)
LUA_KCONTEXT lua_KContext
int(* lua_KFunction)(lua_State *L, int status, lua_KContext ctx)
struct CallInfo * previous
struct CallInfo::@64::@65 l
const Instruction * savedpc
unsigned short callstatus
struct CallInfo::@64::@66 c
TString * strcache[STRCACHE_N][STRCACHE_M]
struct lua_State * mainthread
struct Table * mt[NUM_TAGS]
const lua_Number * version
struct lua_longjmp * errorJmp
const Instruction * oldpc