32 #define noLuaClosure(f) ((f) == NULL || (f)->c.tt == LUA_TCCL)
53 if (func == NULL || mask == 0) {
85 if (level < 0)
return 0;
89 if (level == 0 && ci != &L->
base_ci) {
101 if (s == NULL)
return "?";
108 if (n >= ci->
u.
l.base - ci->
func - nparams)
111 *pos = ci->
func + nparams +
n;
119 const char *
name = NULL;
133 if (limit - base >= n && n > 0)
134 name =
"(*temporary)";
138 *pos = base + (n - 1);
217 for (; *
what; what++) {
228 ar->
nups = (f == NULL) ? 0 : f->
c.nupvalues;
285 if (strchr(what,
'f')) {
289 if (strchr(what,
'L'))
320 if (what && *what ==
'c') {
343 for (pc = 0; pc < lastpc; pc++) {
350 if (a <= reg && reg <= a + b)
367 int dest = pc + 1 +
b;
369 if (pc < dest && dest <= lastpc) {
370 if (dest > jmptarget)
415 kname(p, pc, k, name);
416 return (vn && strcmp(vn,
LUA_ENV) == 0) ?
"global" :
"field";
434 kname(p, pc, k, name);
454 *name =
"for iterator";
455 return "for iterator";
478 *name =
getstr(
G(L)->tmname[tm]);
493 if (o == p)
return 1;
502 for (i = 0; i < c->nupvalues; i++) {
514 const char *
name = NULL;
516 const char *kind = NULL;
565 buff[0] =
'?'; buff[1] =
'\0';
static const char * getupvalname(CallInfo *ci, const TValue *o, const char **name)
const char * luaO_pushvfstring(lua_State *L, const char *fmt, va_list argp)
l_noret luaG_runerror(lua_State *L, const char *fmt,...)
const TValue * luaV_tonumber(const TValue *obj, TValue *n)
static const char * upvalname(Proto *p, int uv)
#define setbvalue(obj, x)
LUA_API lua_Hook lua_gethook(lua_State *L)
#define getfuncline(f, pc)
void(* lua_Hook)(lua_State *L, lua_Debug *ar)
LUA_API int lua_gethookmask(lua_State *L)
static int currentpc(CallInfo *ci)
static int currentline(CallInfo *ci)
const char * what() const
char short_src[LUA_IDSIZE]
LUA_API int lua_getstack(lua_State *L, int level, lua_Debug *ar)
static int findsetreg(Proto *p, int lastpc, int reg)
l_noret luaG_errormsg(lua_State *L)
static int filterpc(int pc, int jmptarget)
static const char * findvararg(CallInfo *ci, int n, StkId *pos)
static int isinstack(CallInfo *ci, const TValue *o)
static const char * findlocal(lua_State *L, CallInfo *ci, int n, StkId *pos)
GLdouble GLdouble GLdouble b
l_noret luaG_typeerror(lua_State *L, const TValue *o, const char *op)
#define sethvalue(L, obj, x)
#define restorestack(L, n)
const char * luaF_getlocalname(const Proto *f, int local_number, int pc)
LUA_API int lua_sethook(lua_State *L, lua_Hook func, int mask, int count)
GLboolean GLboolean GLboolean GLboolean a
LUA_API const char * lua_setlocal(lua_State *L, const lua_Debug *ar, int n)
GLuint GLuint GLsizei count
#define resethookcount(L)
l_noret luaG_ordererror(lua_State *L, const TValue *p1, const TValue *p2)
static const char * getobjname(Proto *p, int lastpc, int reg, const char **name)
Table * luaH_new(lua_State *L)
l_noret luaD_throw(lua_State *L, int errcode)
static void addinfo(lua_State *L, const char *msg)
LUA_API int lua_getinfo(lua_State *L, const char *what, lua_Debug *ar)
static void msg(const char *act, debug_info &i, const char *to="", const char *result="")
void luaH_setint(lua_State *L, Table *t, int key, TValue *value)
LUA_API const char * lua_getlocal(lua_State *L, const lua_Debug *ar, int n)
const char * luaO_pushfstring(lua_State *L, const char *fmt,...)
void luaO_chunkid(char *out, const char *source, size_t bufflen)
GLuint const GLchar * name
struct CallInfo::@16::@17 l
#define api_check(l, e, msg)
struct CallInfo * previous
LUA_API int lua_gethookcount(lua_State *L)
void luaD_call(lua_State *L, StkId func, int nResults, int allowyield)
l_noret luaG_concaterror(lua_State *L, StkId p1, StkId p2)
static void collectvalidlines(lua_State *L, Closure *f)
static int auxgetinfo(lua_State *L, const char *what, lua_Debug *ar, Closure *f, CallInfo *ci)
static void kname(Proto *p, int pc, int c, const char **name)
const Instruction * oldpc
static void funcinfo(lua_Debug *ar, Closure *cl)
static const char * getfuncname(lua_State *L, CallInfo *ci, const char **name)
l_noret luaG_aritherror(lua_State *L, const TValue *p1, const TValue *p2)