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

Function preinit_thread

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

** preinitialize a thread with consistent values without allocating ** any memory (to avoid errors) */

Source from the content-addressed store, hash-verified

222** any memory (to avoid errors)
223*/
224static void preinit_thread(lua_State *L, global_State *g) {
225 G(L) = g;
226 L->stack = nullptr;
227 L->ci = nullptr;
228 L->nci = 0;
229 L->stacksize = 0;
230 L->twups = L; /* thread has no upvalues */
231 L->errorJmp = nullptr;
232 L->nCcalls = 0;
233 L->hook = nullptr;
234 L->hookmask = 0;
235 L->basehookcount = 0;
236 L->allowhook = 1;
237 resethookcount(L);
238 L->openupval = nullptr;
239 L->nny = 1;
240 L->status = LUA_OK;
241 L->errfunc = 0;
242}
243
244
245static void close_state(lua_State *L) {

Callers 2

lua_newthreadFunction · 0.85
lua_newstateFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected