LUA_CHECKSTACK(3) Library Functions Manual LUA_CHECKSTACK(3)

lua_checkstackensures that there are at least extra free stack slots in the stack, function indicator [-0, +0, m]

#include <lua.h>

int
lua_checkstack(lua_State *L, int extra);

() ensures that there are at least extra free stack slots in the stack. It returns false if it cannot grow the stack to that size. This function never shrinks the stack; if the stack is already larger than the new size, it is left unchanged.

Roberto Ierusalimschy, Luiz Henrique de Figueiredo, and Waldemar Celes, Lua 5.1 Reference Manual.

The lua_checkstack() manual page is based on Lua Reference Manual 5.1 and was created by Sergey Bronnikov.

July 14, 2022 Debian