Lightweight C interface to the package loader. More...
Lightweight C interface to the package loader.
Definition in file lua_loadlib.h.
Go to the source code of this file.
#define | LUAR_MODULE_NOTFOUND 50 |
Error code for when a modules is not found. More... | |
int | lua_riot_getloader (lua_State *L, const char *name) |
Load a module as a chunk. More... | |
#define LUAR_MODULE_NOTFOUND 50 |
Error code for when a modules is not found.
The numeric value is chosen so that there is no collision with Lua's own error codes.
Definition at line 31 of file lua_loadlib.h.
int lua_riot_getloader | ( | lua_State * | L, |
const char * | name | ||
) |
Load a module as a chunk.
This function is a lightweight "require". It does not require the "package" module to be loaded and does not register the module. Only the builtin tables are searched.
Upon successful execution, the compiled chunk will be at the top of the lua stack.
L | Initialized Lua interpreter state. |
name | Name of the module. |