MCPcopy Create free account
hub / github.com/Achain-Dev/Achain / luaB_exit

Function luaB_exit

src/Chain/libraries/glua/lbaselib.cpp:211–224  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

209}
210
211static int luaB_exit(lua_State *L) {
212 if (lua_gettop(L) < 1 || !lua_isstring(L, -1))
213 {
214 global_glua_chain_api->throw_exception(L, THINKYOUNG_API_THROW_ERROR, "empty error");
215 // thinkyoung::lua::lib::notify_lua_state_stop(L);
216 return 0;
217 }
218 const char *msg = luaL_checkstring(L, -1);
219 lua_set_run_error(L, msg);
220 global_glua_chain_api->throw_exception(L, THINKYOUNG_API_THROW_ERROR, msg);
221 L->force_stopping = true;
222 // thinkyoung::lua::lib::notify_lua_state_stop(L);
223 return 0;
224}
225
226static int luaB_getmetatable(lua_State *L) {
227 luaL_checkany(L, 1);

Callers

nothing calls this directly

Calls 4

lua_gettopFunction · 0.85
lua_isstringFunction · 0.85
lua_set_run_errorFunction · 0.85
throw_exceptionMethod · 0.45

Tested by

no test coverage detected