On 07/04/2017 03:28 PM, [email protected] wrote:
The following lua 5.2 and 5.3 compat change should be checked for runtime correctness by someone more knowledgeable about lua.Index: modules/lua/lua_apr.c --- modules/lua/lua_apr.c (original) +++ modules/lua/lua_apr.c Tue Jul 4 20:48:43 2017 @@ -82,7 +82,11 @@ static const luaL_Reg lua_table_methods[ int ap_lua_init(lua_State *L, apr_pool_t *p) { luaL_newmetatable(L, "Apr.Table"); +#if LUA_VERSION_NUM < 502 luaL_register(L, "apr_table", lua_table_methods); +#else + luaL_newlib(L, lua_table_methods); +#endif
So the effective change is that "apr_table" is no longer a global name, is that correct? Looks like you brought this up in [1] but there was never a final decision.
Everything else in the patch looks good to me, and passes the test suite on Ubuntu 16.04 with Lua 5.1/2/3.
--Jacob [1] https://bz.apache.org/bugzilla/show_bug.cgi?id=56753#c10
