MCPcopy Create free account
hub / github.com/EmmyLua/EmmyLuaDebugger / luaL_checkversion_

Function luaL_checkversion_

third-party/lua-5.3.5/src/lauxlib.c:1033–1042  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1031
1032
1033LUALIB_API void luaL_checkversion_ (lua_State *L, lua_Number ver, size_t sz) {
1034 const lua_Number *v = lua_version(L);
1035 if (sz != LUAL_NUMSIZES) /* check numeric types */
1036 luaL_error(L, "core and library have incompatible numeric types");
1037 if (v != lua_version(NULL))
1038 luaL_error(L, "multiple Lua VMs detected");
1039 else if (*v != ver)
1040 luaL_error(L, "version mismatch: app. needs %f, Lua core provides %f",
1041 (LUAI_UACNUMBER)ver, (LUAI_UACNUMBER)*v);
1042}
1043

Callers

nothing calls this directly

Calls 2

lua_versionFunction · 0.70
luaL_errorFunction · 0.70

Tested by

no test coverage detected