MCPcopy Create free account
hub / github.com/DFHack/dfhack / luaL_checkstack

Function luaL_checkstack

depends/lua/src/lauxlib.c:368–375  ·  view source on GitHub ↗

** Ensures the stack has at least 'space' extra slots, raising an error ** if it cannot fulfill the request. (The error handling needs a few ** extra slots to format the error message. In case of an error without ** this extra space, Lua will generate the same 'stack overflow' error, ** but without 'msg'.) */

Source from the content-addressed store, hash-verified

366** but without 'msg'.)
367*/
368LUALIB_API void luaL_checkstack (lua_State *L, int space, const char *msg) {
369 if (!lua_checkstack(L, space)) {
370 if (msg)
371 luaL_error(L, "stack overflow (%s)", msg);
372 else
373 luaL_error(L, "stack overflow");
374 }
375}
376
377
378LUALIB_API void luaL_checktype (lua_State *L, int arg, int t) {

Callers 15

dfhack_curry_wrapFunction · 0.85
dfhack_event_callFunction · 0.85
doRunLuaFunctionMethod · 0.85
dfhack_random_unitvectorFunction · 0.85
l_printFunction · 0.85
pushargsFunction · 0.85
generic_readerFunction · 0.85
str_byteFunction · 0.85
push_capturesFunction · 0.85
str_unpackFunction · 0.85
luaL_tracebackFunction · 0.85
luaL_setfuncsFunction · 0.85

Calls 2

lua_checkstackFunction · 0.85
luaL_errorFunction · 0.85

Tested by

no test coverage detected