MCPcopy Create free account
hub / github.com/OpenApoc/OpenApoc / handleLuaError

Function handleLuaError

framework/luaframework.cpp:243–251  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

241}
242
243void handleLuaError(lua_State *L, LogLevel level)
244{
245 size_t count;
246 const char *buf = luaL_checklstring(L, -1, &count);
247 UString str{buf, count};
248 // TODO: unwind stack and show previously called c function?
249 Log(level, LOGGER_PREFIX, "Lua: " + str);
250 lua_pop(L, 1); // pop error object we just printed
251}
252
253void pushLuaFramework(lua_State *L)
254{

Callers 4

initMethod · 0.85
callHookMethod · 0.85
runScriptMethod · 0.85
pushLuaFrameworkFunction · 0.85

Calls 1

LogFunction · 0.85

Tested by

no test coverage detected