File nut/include/lua/lstate.h


Included Files


Preprocessor definitions

#define lstate_h

#define gt( L )

#define registry( L )

#define EXTRA_STACK 5

#define BASIC_CI_SIZE 8

#define BASIC_STACK_SIZE

#define curr_func( L )

#define ci_func( ci )

#define f_isLua( ci )

#define isLua( ci )

#define G( L )

#define rawgco2ts( o )

#define gco2ts( o )

#define rawgco2u( o )

#define gco2u( o )

#define gco2cl( o )

#define gco2h( o )

#define gco2p( o )

#define gco2uv( o )

#define ngcotouv( o )

#define gco2th( o )

#define obj2gco( v )


Typedef stringtable

typedef struct stringtable stringtable
struct stringtable  
   {  
      GCObject** hash;  
      lu_int32 nuse;  
      int size;  
   }  

Typedef CallInfo

typedef struct CallInfo CallInfo
struct CallInfo  
   {  
      StkId base;  
      StkId func;  
      StkId top;  
      const Instruction* savedpc;  
      int nresults;  
      int tailcalls;  
   }  

Typedef global_State

typedef struct global_State global_State
struct global_State  
   {  
      stringtable strt;  
      lua_Alloc frealloc;  
      void* ud;  
      lu_byte currentwhite;  
      lu_byte gcstate;  
      int sweepstrgc;  
      GCObject* rootgc;  
      GCObject** sweepgc;  
      GCObject* gray;  
      GCObject* grayagain;  
      GCObject* weak;  
      GCObject* tmudata;  
      Mbuffer buff;  
      lu_mem GCthreshold;  
      lu_mem totalbytes;  
      lu_mem estimate;  
      lu_mem gcdept;  
      int gcpause;  
      int gcstepmul;  
      lua_CFunction panic;  
      TValue l_registry;  
      struct lua_State* mainthread;  
      UpVal uvhead;  
      struct Table* mt[(8+1)];  
      TString* tmname[TM_N];  
   }  

Type struct lua_State

struct lua_State
struct lua_State  
   {  
      GCObject* next;  
      lu_byte tt;  
      lu_byte marked;  
      lu_byte status;  
      StkId top;  
      StkId base;  
      global_State* l_G;  
      CallInfo* ci;  
      const Instruction* savedpc;  
      StkId stack_last;  
      StkId stack;  
      CallInfo* end_ci;  
      CallInfo* base_ci;  
      int stacksize;  
      int size_ci;  
      unsigned short nCcalls;  
      unsigned short baseCcalls;  
      lu_byte hookmask;  
      lu_byte allowhook;  
      int basehookcount;  
      int hookcount;  
      lua_Hook hook;  
      TValue l_gt;  
      TValue env;  
      GCObject* openupval;  
      GCObject* gclist;  
      struct lua_longjmp* errorJmp;  
      ptrdiff_t errfunc;  
   }  

Type union GCObject

union GCObject
union GCObject  
   {  
      GCheader gch;  
      union TString ts;  
      union Udata u;  
      union Closure cl;  
      struct Table h;  
      struct Proto p;  
      struct UpVal uv;  
      struct lua_State th;  
   }