lua-users home
lua-l archive

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

> It's a bit strange that lua would not take appropriate measure to
> enlarge the stack automatically. Silently stumping data is even more
> strange.

The C API does not hold hands. It assumes you know what you're doing,
just like the standard C library, which never tests pointers for NULL
for instance.

The manual says:
   As in most C libraries, the Lua API functions do not check their
   arguments for validity or consistency. However, you can change this
   behavior by compiling Lua with a proper definition for the macro
   luai_apicheck, in file luaconf.h.