Hisham <[email protected]> wrote: > That code is useful for indicating places that need to be changed, but > not ready for merging. I've already committed some changes equivalent > to the ones in ansible07's commit 0825ce3aa8 [1], which can be seen > here [2], but there are some issues:
Thanks for the feedback. As I had mentioned previously, my main goal was to just start the discussion. Having the changes for Lua 5.2 integrate well with the existing codebase is very important, but wasn't something that I put much effort into. > * during "configure" it assumes there's a binary called "lua" in the > path, something we can't do. > * we'll probably need configure flags for explicitly selecting lua 5.1 > or 5.2, as some users may have both OK, I understand. If Lua 5.1 is installed, then should we assume this as the default unless the user has specified otherwise? > * os.execute is used in a couple other places as well, and it would be > better not to have "if _VERSION == 'Lua 5.2'" in several places in the > code Should the Lua version be exported by luarocks.cfg? > * ansible07 added a Lua 5.2 version of setfenv. I haven't studied the > matter closely, but I remember reading in lua-l that there's no way to > implement a 100% equivalent setfenv in Lua 5.2. The one posted there > probably works well enough for our simple use in luarocks.persist, but > it does load the debug library, which is something I wouldn't want to > have in the module dependency chain for the LuaRocks loader. Instead > of adding a setfenv replacement, it's better to reimplement > persist.load_into_table in terms of load(). At the time I didn't understand that code well enough, so I took the easy way out. > * the changes in Makefile/configure need equivalent tweaks in install.bat Right. There is a hardcoded reference to Lua 5.1.2 in there still, does that need to stay? > I wonder: apart from these changes, is the rest of the code Lua 5.2 > compatible? (assuming LUA_COMPAT_ALL of course) I haven't touched that code in a few months, and have just been using Lua 5.1 for projects at work recently. At any rate, I had only done light testing with Lua 5.2. I was able to install and remove rocks, but many of the packages themselves didn't support 5.2 so I had to skip over them. James Graves ------------------------------------------------------------------------------ Keep Your Developer Skills Current with LearnDevNow! The most comprehensive online learning library for Microsoft developers is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, Metro Style Apps, more. Free future releases when you subscribe now! http://p.sf.net/sfu/learndevnow-d2d _______________________________________________ Luarocks-developers mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/luarocks-developers
