lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Mike Pall wrote:
> Umm, ok. But the only time lua_cpcall is really useful is when you
> use it at the outermost frame and then only for the main thread
> (i.e. only once). This cannot fail because the stack is preallocated
> in lua_open (-> lua_newstate -> f_luaopen) to BASIC_STACK_SIZE (2*20
> elements).

I use it when I have C calling C and I wish to preserve the Lua stack state.