MCPcopy Create free account
hub / github.com/ArduPilot/ardupilot / luaL_openlib

Function luaL_openlib

libraries/AP_Scripting/lua/src/lauxlib.c:918–929  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

916
917
918LUALIB_API void luaL_openlib (lua_State *L, const char *libname,
919 const luaL_Reg *l, int nup) {
920 luaL_checkversion(L);
921 if (libname) {
922 luaL_pushmodule(L, libname, libsize(l)); /* get/create library table */
923 lua_insert(L, -(nup + 1)); /* move library table to below upvalues */
924 }
925 if (l)
926 luaL_setfuncs(L, l, nup);
927 else
928 lua_pop(L, nup); /* remove upvalues */
929}
930
931#endif
932/* }====================================================== */

Callers

nothing calls this directly

Calls 3

luaL_pushmoduleFunction · 0.85
libsizeFunction · 0.85
luaL_setfuncsFunction · 0.85

Tested by

no test coverage detected