MCPcopy Create free account
hub / github.com/EmmyLua/EmmyLuaDebugger / luaG_addinfo

Function luaG_addinfo

third-party/lua-5.4.6/src/ldebug.c:823–832  ·  view source on GitHub ↗

add src:line information to 'msg' */

Source from the content-addressed store, hash-verified

821
822/* add src:line information to 'msg' */
823const char *luaG_addinfo (lua_State *L, const char *msg, TString *src,
824 int line) {
825 char buff[LUA_IDSIZE];
826 if (src)
827 luaO_chunkid(buff, getstr(src), tsslen(src));
828 else { /* no source available; use "?" instead */
829 buff[0] = '?'; buff[1] = '\0';
830 }
831 return luaO_pushfstring(L, "%s:%d: %s", buff, line, msg);
832}
833
834
835l_noret luaG_errormsg (lua_State *L) {

Callers 2

lexerrorFunction · 0.70
luaG_runerrorFunction · 0.70

Calls 2

luaO_chunkidFunction · 0.70
luaO_pushfstringFunction · 0.70

Tested by

no test coverage detected