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

Function luaE_resetthread

third-party/lua-5.5.0/src/lstate.c:310–321  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

308
309
310TStatus luaE_resetthread (lua_State *L, TStatus status) {
311 resetCI(L);
312 if (status == LUA_YIELD)
313 status = LUA_OK;
314 status = luaD_closeprotected(L, 1, status);
315 if (status != LUA_OK) /* errors? */
316 luaD_seterrorobj(L, status, L->stack.p + 1);
317 else
318 L->top.p = L->stack.p + 1;
319 luaD_reallocstack(L, cast_int(L->ci->top.p - L->stack.p), 0);
320 return status;
321}
322
323
324LUA_API int lua_closethread (lua_State *L, lua_State *from) {

Callers 2

lua_closethreadFunction · 0.70
luaD_throwFunction · 0.70

Calls 4

resetCIFunction · 0.85
luaD_closeprotectedFunction · 0.70
luaD_seterrorobjFunction · 0.70
luaD_reallocstackFunction · 0.70

Tested by

no test coverage detected