The Battle for Wesnoth  1.15.11+dev
Macros | Functions
ldebug.h File Reference
#include "lstate.h"
Include dependency graph for ldebug.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define pcRel(pc, p)   (cast_int((pc) - (p)->code) - 1)
 
#define ci_func(ci)   (clLvalue(s2v((ci)->func)))
 
#define resethookcount(L)   (L->hookcount = L->basehookcount)
 
#define ABSLINEINFO   (-0x80)
 

Functions

LUAI_FUNC int luaG_getfuncline (const Proto *f, int pc)
 
LUAI_FUNC const char * luaG_findlocal (lua_State *L, CallInfo *ci, int n, StkId *pos)
 
LUAI_FUNC l_noret luaG_typeerror (lua_State *L, const TValue *o, const char *opname)
 
LUAI_FUNC l_noret luaG_forerror (lua_State *L, const TValue *o, const char *what)
 
LUAI_FUNC l_noret luaG_concaterror (lua_State *L, const TValue *p1, const TValue *p2)
 
LUAI_FUNC l_noret luaG_opinterror (lua_State *L, const TValue *p1, const TValue *p2, const char *msg)
 
LUAI_FUNC l_noret luaG_tointerror (lua_State *L, const TValue *p1, const TValue *p2)
 
LUAI_FUNC l_noret luaG_ordererror (lua_State *L, const TValue *p1, const TValue *p2)
 
LUAI_FUNC l_noret luaG_runerror (lua_State *L, const char *fmt,...)
 
LUAI_FUNC const char * luaG_addinfo (lua_State *L, const char *msg, TString *src, int line)
 
LUAI_FUNC l_noret luaG_errormsg (lua_State *L)
 
LUAI_FUNC int luaG_traceexec (lua_State *L, const Instruction *pc)
 

Macro Definition Documentation

◆ ABSLINEINFO

#define ABSLINEINFO   (-0x80)

Definition at line 27 of file ldebug.h.

Referenced by luaG_getfuncline(), nextline(), removelastlineinfo(), and savelineinfo().

◆ ci_func

#define ci_func (   ci)    (clLvalue(s2v((ci)->func)))

◆ pcRel

#define pcRel (   pc,
  p 
)    (cast_int((pc) - (p)->code) - 1)

Definition at line 14 of file ldebug.h.

Referenced by currentpc(), luaG_traceexec(), and rethook().

◆ resethookcount

#define resethookcount (   L)    (L->hookcount = L->basehookcount)

Definition at line 21 of file ldebug.h.

Referenced by lua_newthread(), lua_sethook(), luaG_traceexec(), and preinit_thread().

Function Documentation

◆ luaG_addinfo()

LUAI_FUNC const char* luaG_addinfo ( lua_State L,
const char *  msg,
TString src,
int  line 
)

Definition at line 742 of file ldebug.cpp.

References getstr, LUA_IDSIZE, luaO_chunkid(), luaO_pushfstring(), and tsslen.

Referenced by lexerror(), and luaG_runerror().

◆ luaG_concaterror()

LUAI_FUNC l_noret luaG_concaterror ( lua_State L,
const TValue p1,
const TValue p2 
)

Definition at line 706 of file ldebug.cpp.

References cvt2str, luaG_typeerror(), and ttisstring.

Referenced by luaT_tryconcatTM().

◆ luaG_errormsg()

LUAI_FUNC l_noret luaG_errormsg ( lua_State L)

◆ luaG_findlocal()

LUAI_FUNC const char* luaG_findlocal ( lua_State L,
CallInfo ci,
int  n,
StkId pos 
)

◆ luaG_forerror()

LUAI_FUNC l_noret luaG_forerror ( lua_State L,
const TValue o,
const char *  what 
)

Definition at line 700 of file ldebug.cpp.

References luaG_runerror(), and luaT_objtypename().

Referenced by forlimit(), and forprep().

◆ luaG_getfuncline()

LUAI_FUNC int luaG_getfuncline ( const Proto f,
int  pc 
)

Definition at line 87 of file ldebug.cpp.

References ABSLINEINFO, getbaseline(), Proto::lineinfo, and lua_assert.

Referenced by changedline(), getcurrentline(), luaG_traceexec(), and nextline().

◆ luaG_opinterror()

LUAI_FUNC l_noret luaG_opinterror ( lua_State L,
const TValue p1,
const TValue p2,
const char *  msg 
)

Definition at line 712 of file ldebug.cpp.

References luaG_typeerror(), and ttisnumber.

Referenced by luaT_trybinTM().

◆ luaG_ordererror()

LUAI_FUNC l_noret luaG_ordererror ( lua_State L,
const TValue p1,
const TValue p2 
)

Definition at line 731 of file ldebug.cpp.

References luaG_runerror(), and luaT_objtypename().

Referenced by luaT_callorderTM().

◆ luaG_runerror()

LUAI_FUNC l_noret luaG_runerror ( lua_State L,
const char *  fmt,
  ... 
)

◆ luaG_tointerror()

LUAI_FUNC l_noret luaG_tointerror ( lua_State L,
const TValue p1,
const TValue p2 
)

Definition at line 723 of file ldebug.cpp.

References luaG_runerror(), tointegerns, and varinfo().

Referenced by luaT_trybinTM().

◆ luaG_traceexec()

LUAI_FUNC int luaG_traceexec ( lua_State L,
const Instruction pc 
)

◆ luaG_typeerror()

LUAI_FUNC l_noret luaG_typeerror ( lua_State L,
const TValue o,
const char *  opname 
)