#include <stdarg.h>#include "llimits.h"#include "lua.h"

Go to the source code of this file.
Classes | |
| struct | GCheader |
| union | Value |
| struct | lua_TValue |
| union | TString |
| union | Udata |
| struct | Upvaldesc |
| struct | LocVar |
| struct | Proto |
| struct | UpVal |
| struct | CClosure |
| struct | LClosure |
| union | Closure |
| union | TKey |
| struct | Node |
| struct | Table |
Defines | |
| #define | LUA_TPROTO LUA_NUMTAGS |
| #define | LUA_TUPVAL (LUA_NUMTAGS+1) |
| #define | LUA_TDEADKEY (LUA_NUMTAGS+2) |
| #define | LUA_TOTALTAGS (LUA_TUPVAL+2) |
| #define | LUA_TLCL (LUA_TFUNCTION | (0 << 4)) |
| #define | LUA_TLCF (LUA_TFUNCTION | (1 << 4)) |
| #define | LUA_TCCL (LUA_TFUNCTION | (2 << 4)) |
| #define | BIT_ISCOLLECTABLE (1 << 6) |
| #define | ctb(t) ((t) | BIT_ISCOLLECTABLE) |
| #define | CommonHeader GCObject *next; lu_byte tt; lu_byte marked |
| #define | numfield lua_Number n; |
| #define | TValuefields Value value_; int tt_ |
| #define | NILCONSTANT {NULL}, LUA_TNIL |
| #define | val_(o) ((o)->value_) |
| #define | num_(o) (val_(o).n) |
| #define | rttype(o) ((o)->tt_) |
| #define | ttype(o) (rttype(o) & 0x3F) |
| #define | ttypenv(o) (rttype(o) & 0x0F) |
| #define | checktag(o, t) (rttype(o) == (t)) |
| #define | ttisnumber(o) checktag((o), LUA_TNUMBER) |
| #define | ttisnil(o) checktag((o), LUA_TNIL) |
| #define | ttisboolean(o) checktag((o), LUA_TBOOLEAN) |
| #define | ttislightuserdata(o) checktag((o), LUA_TLIGHTUSERDATA) |
| #define | ttisstring(o) checktag((o), ctb(LUA_TSTRING)) |
| #define | ttistable(o) checktag((o), ctb(LUA_TTABLE)) |
| #define | ttisfunction(o) (ttypenv(o) == LUA_TFUNCTION) |
| #define | ttisclosure(o) ((rttype(o) & 0x1F) == LUA_TFUNCTION) |
| #define | ttisCclosure(o) checktag((o), ctb(LUA_TCCL)) |
| #define | ttisLclosure(o) checktag((o), ctb(LUA_TLCL)) |
| #define | ttislcf(o) checktag((o), LUA_TLCF) |
| #define | ttisuserdata(o) checktag((o), ctb(LUA_TUSERDATA)) |
| #define | ttisthread(o) checktag((o), ctb(LUA_TTHREAD)) |
| #define | ttisdeadkey(o) checktag((o), LUA_TDEADKEY) |
| #define | ttisequal(o1, o2) (rttype(o1) == rttype(o2)) |
| #define | nvalue(o) check_exp(ttisnumber(o), num_(o)) |
| #define | gcvalue(o) check_exp(iscollectable(o), val_(o).gc) |
| #define | pvalue(o) check_exp(ttislightuserdata(o), val_(o).p) |
| #define | rawtsvalue(o) check_exp(ttisstring(o), &val_(o).gc->ts) |
| #define | tsvalue(o) (&rawtsvalue(o)->tsv) |
| #define | rawuvalue(o) check_exp(ttisuserdata(o), &val_(o).gc->u) |
| #define | uvalue(o) (&rawuvalue(o)->uv) |
| #define | clvalue(o) check_exp(ttisclosure(o), &val_(o).gc->cl) |
| #define | clLvalue(o) check_exp(ttisLclosure(o), &val_(o).gc->cl.l) |
| #define | clCvalue(o) check_exp(ttisCclosure(o), &val_(o).gc->cl.c) |
| #define | fvalue(o) check_exp(ttislcf(o), val_(o).f) |
| #define | hvalue(o) check_exp(ttistable(o), &val_(o).gc->h) |
| #define | bvalue(o) check_exp(ttisboolean(o), val_(o).b) |
| #define | thvalue(o) check_exp(ttisthread(o), &val_(o).gc->th) |
| #define | deadvalue(o) check_exp(ttisdeadkey(o), cast(void *, val_(o).gc)) |
| #define | l_isfalse(o) (ttisnil(o) || (ttisboolean(o) && bvalue(o) == 0)) |
| #define | iscollectable(o) (rttype(o) & BIT_ISCOLLECTABLE) |
| #define | righttt(obj) (ttypenv(obj) == gcvalue(obj)->gch.tt) |
| #define | checkliveness(g, obj) |
| #define | settt_(o, t) ((o)->tt_=(t)) |
| #define | setnvalue(obj, x) { TValue *io=(obj); num_(io)=(x); settt_(io, LUA_TNUMBER); } |
| #define | changenvalue(o, x) check_exp(ttisnumber(o), num_(o)=(x)) |
| #define | setnilvalue(obj) settt_(obj, LUA_TNIL) |
| #define | setfvalue(obj, x) { TValue *io=(obj); val_(io).f=(x); settt_(io, LUA_TLCF); } |
| #define | setpvalue(obj, x) { TValue *io=(obj); val_(io).p=(x); settt_(io, LUA_TLIGHTUSERDATA); } |
| #define | setbvalue(obj, x) { TValue *io=(obj); val_(io).b=(x); settt_(io, LUA_TBOOLEAN); } |
| #define | setgcovalue(L, obj, x) |
| #define | setsvalue(L, obj, x) |
| #define | setuvalue(L, obj, x) |
| #define | setthvalue(L, obj, x) |
| #define | setclLvalue(L, obj, x) |
| #define | setclCvalue(L, obj, x) |
| #define | sethvalue(L, obj, x) |
| #define | setptvalue(L, obj, x) |
| #define | setdeadvalue(obj) settt_(obj, LUA_TDEADKEY) |
| #define | setobj(L, obj1, obj2) |
| #define | setobjs2s setobj |
| #define | setobj2s setobj |
| #define | setsvalue2s setsvalue |
| #define | sethvalue2s sethvalue |
| #define | setptvalue2s setptvalue |
| #define | setobjt2t setobj |
| #define | setobj2t setobj |
| #define | setobj2n setobj |
| #define | setsvalue2n setsvalue |
| #define | luai_checknum(L, o, c) { /* empty */ } |
| #define | getstr(ts) cast(const char *, (ts) + 1) |
| #define | svalue(o) getstr(rawtsvalue(o)) |
| #define | ClosureHeader CommonHeader; lu_byte isC; lu_byte nupvalues; GCObject *gclist |
| #define | isLfunction(o) ttisLclosure(o) |
| #define | getproto(o) (clLvalue(o)->p) |
| #define | lmod(s, size) (check_exp((size&(size-1))==0, (cast(int, (s) & ((size)-1))))) |
| #define | twoto(x) (1<<(x)) |
| #define | sizenode(t) (twoto((t)->lsizenode)) |
| #define | luaO_nilobject (&luaO_nilobject_) |
Typedefs | |
| typedef union GCObject | GCObject |
| typedef struct GCheader | GCheader |
| typedef union Value | Value |
| typedef struct lua_TValue | TValue |
| typedef TValue * | StkId |
| typedef union TString | TString |
| typedef union Udata | Udata |
| typedef struct Upvaldesc | Upvaldesc |
| typedef struct LocVar | LocVar |
| typedef struct Proto | Proto |
| typedef struct UpVal | UpVal |
| typedef struct CClosure | CClosure |
| typedef struct LClosure | LClosure |
| typedef union Closure | Closure |
| typedef union TKey | TKey |
| typedef struct Node | Node |
| typedef struct Table | Table |
Functions | |
| LUAI_FUNC int | luaO_int2fb (unsigned int x) |
| LUAI_FUNC int | luaO_fb2int (int x) |
| LUAI_FUNC int | luaO_ceillog2 (unsigned int x) |
| LUAI_FUNC lua_Number | luaO_arith (int op, lua_Number v1, lua_Number v2) |
| LUAI_FUNC int | luaO_str2d (const char *s, size_t len, lua_Number *result) |
| LUAI_FUNC int | luaO_hexavalue (int c) |
| LUAI_FUNC const char * | luaO_pushvfstring (lua_State *L, const char *fmt, va_list argp) |
| LUAI_FUNC const char * | luaO_pushfstring (lua_State *L, const char *fmt,...) |
| LUAI_FUNC void | luaO_chunkid (char *out, const char *source, size_t len) |
Variables | |
| LUAI_DDEC const TValue | luaO_nilobject_ |
| #define bvalue | ( | o | ) | check_exp(ttisboolean(o), val_(o).b) |
Definition at line 152 of file lobject.h.
Referenced by DumpConstants(), luaV_equalobj_(), mainposition(), and PrintConstant().
| #define changenvalue | ( | o, | ||
| x | ||||
| ) | check_exp(ttisnumber(o), num_(o)=(x)) |
Definition at line 177 of file lobject.h.
Referenced by lua_arith().
| #define checkliveness | ( | g, | ||
| obj | ||||
| ) |
lua_longassert(!iscollectable(obj) || \ (righttt(obj) && !isdead(g,gcvalue(obj))))
| #define clCvalue | ( | o | ) | check_exp(ttisCclosure(o), &val_(o).gc->cl.c) |
Definition at line 149 of file lobject.h.
Referenced by aux_upvalue(), index2addr(), lua_tocfunction(), lua_topointer(), lua_upvalueid(), luaD_precall(), and moveto().
| #define clLvalue | ( | o | ) | check_exp(ttisLclosure(o), &val_(o).gc->cl.l) |
Definition at line 148 of file lobject.h.
Referenced by aux_upvalue(), findvararg(), getupvalref(), lua_getlocal(), lua_load(), lua_topointer(), luaD_precall(), and luaV_execute().
| #define clvalue | ( | o | ) | check_exp(ttisclosure(o), &val_(o).gc->cl) |
Definition at line 147 of file lobject.h.
Referenced by lua_getinfo().
| #define deadvalue | ( | o | ) | check_exp(ttisdeadkey(o), cast(void *, val_(o).gc)) |
Definition at line 155 of file lobject.h.
Referenced by findindex().
| #define fvalue | ( | o | ) | check_exp(ttislcf(o), val_(o).f) |
Definition at line 150 of file lobject.h.
Referenced by lua_tocfunction(), lua_topointer(), luaD_precall(), luaV_equalobj_(), and mainposition().
| #define gcvalue | ( | o | ) | check_exp(iscollectable(o), val_(o).gc) |
Definition at line 141 of file lobject.h.
Referenced by findindex(), iscleared(), lua_rawset(), lua_rawseti(), lua_rawsetp(), lua_setmetatable(), lua_setuservalue(), luaV_equalobj_(), mainposition(), singlestep(), and traverseephemeron().
| #define getproto | ( | o | ) | (clLvalue(o)->p) |
Definition at line 528 of file lobject.h.
Referenced by lua_dump(), and luaV_execute().
| #define getstr | ( | ts | ) | cast(const char *, (ts) + 1) |
Definition at line 412 of file lobject.h.
Referenced by addinfo(), anchor_token(), aux_upvalue(), checkrepeated(), closegoto(), DumpString(), funcinfo(), getfuncname(), l_strcmp(), lexerror(), lua_pushlstring(), lua_pushstring(), luaF_getlocalname(), luaS_newlstr(), PrintDebug(), PrintHeader(), PrintString(), undefgoto(), and upvalname().
| #define hvalue | ( | o | ) | check_exp(ttistable(o), &val_(o).gc->h) |
Definition at line 151 of file lobject.h.
Referenced by lua_getglobal(), lua_getmetatable(), lua_load(), lua_next(), lua_rawget(), lua_rawgeti(), lua_rawgetp(), lua_rawlen(), lua_rawset(), lua_rawseti(), lua_rawsetp(), lua_setglobal(), lua_setmetatable(), lua_setuservalue(), lua_topointer(), luaT_gettmbyobj(), luaV_equalobj_(), luaV_execute(), luaV_gettable(), luaV_objlen(), and luaV_settable().
| #define iscollectable | ( | o | ) | (rttype(o) & BIT_ISCOLLECTABLE) |
Definition at line 160 of file lobject.h.
Referenced by findindex(), iscleared(), and luaV_equalobj_().
| #define isLfunction | ( | o | ) | ttisLclosure(o) |
Definition at line 526 of file lobject.h.
Referenced by lua_dump(), and lua_getlocal().
| #define l_isfalse | ( | o | ) | (ttisnil(o) || (ttisboolean(o) && bvalue(o) == 0)) |
Definition at line 157 of file lobject.h.
Referenced by call_orderTM(), lua_toboolean(), luaV_equalobj_(), luaV_execute(), and luaV_finishOp().
| #define lmod | ( | s, | ||
| size | ||||
| ) | (check_exp((size&(size-1))==0, (cast(int, (s) & ((size)-1))))) |
Definition at line 567 of file lobject.h.
Referenced by luaS_newlstr(), luaS_resize(), and newlstr().
| #define LUA_TCCL (LUA_TFUNCTION | (2 << 4)) |
Definition at line 49 of file lobject.h.
Referenced by aux_upvalue(), lua_topointer(), lua_upvalueid(), and luaD_precall().
| #define LUA_TLCF (LUA_TFUNCTION | (1 << 4)) |
Definition at line 48 of file lobject.h.
Referenced by lua_topointer(), luaD_precall(), luaV_equalobj_(), and mainposition().
| #define LUA_TLCL (LUA_TFUNCTION | (0 << 4)) |
Definition at line 47 of file lobject.h.
Referenced by aux_upvalue(), lua_topointer(), lua_upvalueid(), and luaD_precall().
| #define LUA_TPROTO LUA_NUMTAGS |
Definition at line 22 of file lobject.h.
Referenced by freeobj(), luaF_newproto(), propagatemark(), and reallymarkobject().
| #define LUA_TUPVAL (LUA_NUMTAGS+1) |
Definition at line 23 of file lobject.h.
Referenced by freeobj(), luaF_findupval(), luaF_newupval(), and reallymarkobject().
| #define luai_checknum | ( | L, | ||
| o, | ||||
| c | ||||
| ) | { /* empty */ } |
Definition at line 364 of file lobject.h.
Referenced by lua_pushnumber().
| #define luaO_nilobject (&luaO_nilobject_) |
Definition at line 578 of file lobject.h.
Referenced by luaH_set(), luaH_setint(), luaT_gettmbyobj(), and luaV_settable().
| #define numfield lua_Number n; |
| #define nvalue | ( | o | ) | check_exp(ttisnumber(o), num_(o)) |
Definition at line 140 of file lobject.h.
Referenced by addk(), arrayindex(), DumpConstants(), lua_arith(), lua_tointegerx(), lua_tonumberx(), lua_tounsignedx(), luaH_get(), luaH_getint(), luaH_newkey(), luaV_arith(), luaV_equalobj_(), luaV_execute(), luaV_lessequal(), luaV_lessthan(), luaV_tostring(), mainposition(), and PrintConstant().
| #define pvalue | ( | o | ) | check_exp(ttislightuserdata(o), val_(o).p) |
Definition at line 142 of file lobject.h.
Referenced by lua_touserdata(), luaV_equalobj_(), and mainposition().
| #define rawtsvalue | ( | o | ) | check_exp(ttisstring(o), &val_(o).gc->ts) |
Definition at line 143 of file lobject.h.
Referenced by DumpConstants(), iscleared(), luaH_get(), luaH_getstr(), luaV_concat(), luaV_equalobj_(), luaV_lessequal(), luaV_lessthan(), mainposition(), and PrintConstant().
| #define rawuvalue | ( | o | ) | check_exp(ttisuserdata(o), &val_(o).gc->u) |
Definition at line 145 of file lobject.h.
Referenced by lua_setmetatable(), and lua_touserdata().
| #define righttt | ( | obj | ) | (ttypenv(obj) == gcvalue(obj)->gch.tt) |
| #define setbvalue | ( | obj, | ||
| x | ||||
| ) | { TValue *io=(obj); val_(io).b=(x); settt_(io, LUA_TBOOLEAN); } |
Definition at line 187 of file lobject.h.
Referenced by boolK(), collectvalidlines(), LoadConstants(), lua_pushboolean(), luaV_execute(), and luaX_newstring().
| #define setclCvalue | ( | L, | ||
| obj, | ||||
| x | ||||
| ) |
| #define setclLvalue | ( | L, | ||
| obj, | ||||
| x | ||||
| ) |
{ TValue *io=(obj); \
val_(io).gc=cast(GCObject *, (x)); settt_(io, ctb(LUA_TLCL)); \
checkliveness(G(L),io); }
Definition at line 209 of file lobject.h.
Referenced by f_parser(), luaV_execute(), and pushclosure().
| #define setdeadvalue | ( | obj | ) | settt_(obj, LUA_TDEADKEY) |
Definition at line 229 of file lobject.h.
Referenced by removeentry().
| #define setfvalue | ( | obj, | ||
| x | ||||
| ) | { TValue *io=(obj); val_(io).f=(x); settt_(io, LUA_TLCF); } |
Definition at line 181 of file lobject.h.
Referenced by lua_pushcclosure().
| #define setgcovalue | ( | L, | ||
| obj, | ||||
| x | ||||
| ) |
| #define sethvalue | ( | L, | ||
| obj, | ||||
| x | ||||
| ) |
{ TValue *io=(obj); \
val_(io).gc=cast(GCObject *, (x)); settt_(io, ctb(LUA_TTABLE)); \
checkliveness(G(L),io); }
Definition at line 219 of file lobject.h.
Referenced by collectvalidlines(), init_registry(), lua_createtable(), lua_getmetatable(), lua_getuservalue(), luaV_execute(), and nilK().
| #define sethvalue2s sethvalue |
Definition at line 248 of file lobject.h.
Referenced by open_func().
| #define setnilvalue | ( | obj | ) | settt_(obj, LUA_TNIL) |
Definition at line 179 of file lobject.h.
Referenced by addk(), adjust_varargs(), clearkeys(), clearvalues(), collectvalidlines(), LoadConstants(), lua_getuservalue(), lua_newstate(), lua_pushnil(), lua_settop(), luaD_poscall(), luaD_precall(), luaD_reallocstack(), luaF_newupval(), luaH_newkey(), luaV_execute(), nilK(), setarrayvector(), setnodevector(), stack_init(), and traversestack().
| #define setnvalue | ( | obj, | ||
| x | ||||
| ) | { TValue *io=(obj); num_(io)=(x); settt_(io, LUA_TNUMBER); } |
Definition at line 174 of file lobject.h.
Referenced by addk(), LoadConstants(), lua_pushinteger(), lua_pushnumber(), lua_pushunsigned(), luaH_next(), luaH_setint(), luaK_numberK(), luaO_pushvfstring(), luaV_arith(), luaV_execute(), luaV_objlen(), and luaV_tonumber().
| #define setobj | ( | L, | ||
| obj1, | ||||
| obj2 | ||||
| ) |
{ const TValue *io2=(obj2); TValue *io1=(obj1); \
io1->value_ = io2->value_; io1->tt_ = io2->tt_; \
checkliveness(G(L),io1); }
Definition at line 233 of file lobject.h.
Referenced by addk(), lua_load(), lua_setupvalue(), luaF_close(), luaV_execute(), and moveto().
| #define setobj2n setobj |
Definition at line 255 of file lobject.h.
Referenced by lua_pushcclosure().
| #define setobj2s setobj |
Definition at line 246 of file lobject.h.
Referenced by callTM(), GCTM(), lua_getlocal(), lua_getupvalue(), lua_pushvalue(), lua_rawget(), lua_rawgeti(), lua_rawgetp(), lua_xmove(), luaH_next(), luaV_execute(), luaV_finishOp(), luaV_gettable(), and tryfuncTM().
| #define setobj2t setobj |
Definition at line 253 of file lobject.h.
Referenced by lua_rawset(), lua_rawsetp(), luaH_newkey(), luaH_setint(), and luaV_settable().
| #define setobjs2s setobj |
Definition at line 244 of file lobject.h.
Referenced by adjust_varargs(), callTM(), lua_arith(), lua_getinfo(), lua_insert(), lua_remove(), lua_setlocal(), luaD_poscall(), luaD_throw(), luaG_errormsg(), luaV_execute(), luaV_finishOp(), seterrorobj(), and tryfuncTM().
| #define setobjt2t setobj |
Definition at line 251 of file lobject.h.
Referenced by luaH_resize().
| #define setptvalue | ( | L, | ||
| obj, | ||||
| x | ||||
| ) |
| #define setptvalue2s setptvalue |
Definition at line 249 of file lobject.h.
Referenced by f_parser(), LoadFunction(), and open_func().
| #define setpvalue | ( | obj, | ||
| x | ||||
| ) | { TValue *io=(obj); val_(io).p=(x); settt_(io, LUA_TLIGHTUSERDATA); } |
Definition at line 184 of file lobject.h.
Referenced by lua_pushlightuserdata(), lua_rawgetp(), and lua_rawsetp().
| #define setsvalue | ( | L, | ||
| obj, | ||||
| x | ||||
| ) |
{ TValue *io=(obj); \
val_(io).gc=cast(GCObject *, (x)); settt_(io, ctb(LUA_TSTRING)); \
checkliveness(G(L),io); }
Definition at line 194 of file lobject.h.
Referenced by luaK_numberK(), and luaK_stringK().
| #define setsvalue2n setsvalue |
Definition at line 256 of file lobject.h.
Referenced by LoadConstants().
| #define setsvalue2s setsvalue |
Definition at line 247 of file lobject.h.
Referenced by lua_concat(), lua_getfield(), lua_getglobal(), lua_pushlstring(), lua_pushstring(), lua_setfield(), lua_setglobal(), luaO_pushvfstring(), luaV_concat(), luaV_tostring(), luaX_newstring(), luaY_parser(), pushstr(), resume_error(), and seterrorobj().
| #define setthvalue | ( | L, | ||
| obj, | ||||
| x | ||||
| ) |
{ TValue *io=(obj); \
val_(io).gc=cast(GCObject *, (x)); settt_(io, ctb(LUA_TTHREAD)); \
checkliveness(G(L),io); }
Definition at line 204 of file lobject.h.
Referenced by init_registry(), lua_newthread(), and lua_pushthread().
| #define setuvalue | ( | L, | ||
| obj, | ||||
| x | ||||
| ) |
{ TValue *io=(obj); \
val_(io).gc=cast(GCObject *, (x)); settt_(io, ctb(LUA_TUSERDATA)); \
checkliveness(G(L),io); }
Definition at line 199 of file lobject.h.
Referenced by lua_newuserdata().
| #define sizenode | ( | t | ) | (twoto((t)->lsizenode)) |
Definition at line 572 of file lobject.h.
Referenced by luaH_free(), luaH_next(), luaH_resizearray(), numusehash(), and traversetable().
| #define svalue | ( | o | ) | getstr(rawtsvalue(o)) |
Definition at line 415 of file lobject.h.
Referenced by getobjname(), kname(), lua_tolstring(), luaO_pushvfstring(), luaV_concat(), luaV_tonumber(), and traversetable().
| #define thvalue | ( | o | ) | check_exp(ttisthread(o), &val_(o).gc->th) |
Definition at line 153 of file lobject.h.
Referenced by lua_topointer(), and lua_tothread().
| #define tsvalue | ( | o | ) | (&rawtsvalue(o)->tsv) |
Definition at line 144 of file lobject.h.
Referenced by lua_rawlen(), lua_tolstring(), luaV_concat(), luaV_objlen(), and luaV_tonumber().
| #define ttisCclosure | ( | o | ) | checktag((o), ctb(LUA_TCCL)) |
Definition at line 130 of file lobject.h.
Referenced by lua_iscfunction(), and lua_tocfunction().
| #define ttisclosure | ( | o | ) | ((rttype(o) & 0x1F) == LUA_TFUNCTION) |
Definition at line 129 of file lobject.h.
Referenced by lua_getinfo().
| #define ttisdeadkey | ( | o | ) | checktag((o), LUA_TDEADKEY) |
Definition at line 135 of file lobject.h.
Referenced by findindex().
| #define ttisequal | ( | o1, | ||
| o2 | ||||
| ) | (rttype(o1) == rttype(o2)) |
Definition at line 137 of file lobject.h.
Referenced by luaV_equalobj_().
| #define ttisfunction | ( | o | ) | (ttypenv(o) == LUA_TFUNCTION) |
Definition at line 128 of file lobject.h.
Referenced by GCTM(), lua_getinfo(), luaG_errormsg(), luaV_gettable(), luaV_settable(), and tryfuncTM().
| #define ttislcf | ( | o | ) | checktag((o), LUA_TLCF) |
Definition at line 132 of file lobject.h.
Referenced by index2addr(), lua_iscfunction(), and lua_tocfunction().
| #define ttisLclosure | ( | o | ) | checktag((o), ctb(LUA_TLCL)) |
Definition at line 131 of file lobject.h.
Referenced by getupvalref().
| #define ttislightuserdata | ( | o | ) | checktag((o), LUA_TLIGHTUSERDATA) |
Definition at line 125 of file lobject.h.
Referenced by lua_isuserdata().
| #define ttisnil | ( | o | ) | checktag((o), LUA_TNIL) |
Definition at line 123 of file lobject.h.
Referenced by call_binTM(), clearkeys(), clearvalues(), findindex(), getfreepos(), lua_setmetatable(), lua_setuservalue(), luaH_getn(), luaH_newkey(), luaH_next(), luaH_resize(), luaT_gettm(), luaV_execute(), luaV_finishOp(), luaV_gettable(), luaV_objlen(), luaV_settable(), luaX_newstring(), numusearray(), numusehash(), removeentry(), traverseephemeron(), traversestrongtable(), traverseweakvalue(), and unbound_search().
| #define ttisnumber | ( | o | ) | checktag((o), LUA_TNUMBER) |
Definition at line 122 of file lobject.h.
Referenced by addk(), arrayindex(), lua_arith(), luaG_concaterror(), luaH_getint(), luaH_newkey(), luaV_concat(), luaV_execute(), luaV_lessequal(), luaV_lessthan(), luaV_tonumber(), and luaV_tostring().
| #define ttisstring | ( | o | ) | checktag((o), ctb(LUA_TSTRING)) |
Definition at line 126 of file lobject.h.
Referenced by getobjname(), iscleared(), kname(), lua_tolstring(), luaG_concaterror(), luaH_getstr(), luaV_concat(), luaV_lessequal(), luaV_lessthan(), luaV_tonumber(), and traversetable().
| #define ttistable | ( | o | ) | checktag((o), ctb(LUA_TTABLE)) |
Definition at line 127 of file lobject.h.
Referenced by lua_next(), lua_rawget(), lua_rawgeti(), lua_rawgetp(), lua_rawset(), lua_rawseti(), lua_rawsetp(), lua_setmetatable(), lua_setuservalue(), luaV_execute(), luaV_gettable(), and luaV_settable().
| #define ttisthread | ( | o | ) | checktag((o), ctb(LUA_TTHREAD)) |
Definition at line 134 of file lobject.h.
Referenced by lua_tothread().
| #define ttisuserdata | ( | o | ) | checktag((o), ctb(LUA_TUSERDATA)) |
Definition at line 133 of file lobject.h.
Referenced by lua_getuservalue(), lua_isuserdata(), and lua_setuservalue().
| #define ttype | ( | o | ) | (rttype(o) & 0x3F) |
Definition at line 113 of file lobject.h.
Referenced by aux_upvalue(), DumpConstants(), lua_topointer(), lua_upvalueid(), luaD_precall(), luaV_equalobj_(), mainposition(), and PrintConstant().
| #define ttypenv | ( | o | ) | (rttype(o) & 0x0F) |
Definition at line 117 of file lobject.h.
Referenced by lua_getmetatable(), lua_rawlen(), lua_setmetatable(), lua_touserdata(), lua_type(), luaH_get(), luaT_gettmbyobj(), and luaV_objlen().
| #define twoto | ( | x | ) | (1<<(x)) |
Definition at line 571 of file lobject.h.
Referenced by luaH_resize(), and setnodevector().
| #define uvalue | ( | o | ) | (&rawuvalue(o)->uv) |
Definition at line 146 of file lobject.h.
Referenced by lua_getmetatable(), lua_getuservalue(), lua_rawlen(), lua_setmetatable(), lua_setuservalue(), luaT_gettmbyobj(), and luaV_equalobj_().
| typedef struct lua_TValue TValue |
| LUAI_FUNC lua_Number luaO_arith | ( | int | op, | |
| lua_Number | v1, | |||
| lua_Number | v2 | |||
| ) |
Definition at line 73 of file lobject.c.
References lua_assert, LUA_OPADD, LUA_OPDIV, LUA_OPMOD, LUA_OPMUL, LUA_OPPOW, LUA_OPSUB, and LUA_OPUNM.
Referenced by constfolding(), lua_arith(), and luaV_arith().

| LUAI_FUNC int luaO_ceillog2 | ( | unsigned int | x | ) |
Definition at line 55 of file lobject.c.
Referenced by countint(), and setnodevector().

| LUAI_FUNC void luaO_chunkid | ( | char * | out, | |
| const char * | source, | |||
| size_t | len | |||
| ) |
Definition at line 254 of file lobject.c.
References addstr, LL, POS, PRE, and RETS.
Referenced by addinfo(), funcinfo(), and lexerror().

| LUAI_FUNC int luaO_fb2int | ( | int | x | ) |
Definition at line 48 of file lobject.c.
Referenced by luaV_execute().

| LUAI_FUNC int luaO_hexavalue | ( | int | c | ) |
Definition at line 87 of file lobject.c.
References lisdigit, and ltolower.
Referenced by readhexa(), and readhexaesc().

| LUAI_FUNC int luaO_int2fb | ( | unsigned int | x | ) |
Definition at line 36 of file lobject.c.
References cast_int.
Referenced by constructor().

| LUAI_FUNC const char* luaO_pushfstring | ( | lua_State * | L, | |
| const char * | fmt, | |||
| ... | ||||
| ) |
Definition at line 235 of file lobject.c.
References luaO_pushvfstring().
Referenced by addinfo(), check_match(), checkmode(), checkrepeated(), closegoto(), error(), error_expected(), errorlimit(), GCTM(), lexerror(), luaX_token2str(), txtToken(), and undefgoto().


| LUAI_FUNC const char* luaO_pushvfstring | ( | lua_State * | L, | |
| const char * | fmt, | |||
| va_list | argp | |||
| ) |
Definition at line 180 of file lobject.c.
References cast, cast_num, incr_top, LUA_QL, luaG_runerror(), luaS_newlstr(), luaV_concat(), pushstr(), setnvalue, setsvalue2s, svalue, and lua_State::top.
Referenced by lua_pushfstring(), lua_pushvfstring(), luaG_runerror(), and luaO_pushfstring().


| LUAI_FUNC int luaO_str2d | ( | const char * | s, | |
| size_t | len, | |||
| lua_Number * | result | |||
| ) |
Definition at line 158 of file lobject.c.
References cast_uchar, lisspace, lua_str2number, and lua_strx2number().
Referenced by luaV_tonumber().


| LUAI_DDEC const TValue luaO_nilobject_ |
| Generated by doxygen 1.7.1 on Fri May 25 2012 01:07:22 for The Battle for Wesnoth | Gna! | Forum | Wiki | CIA | devdocs |