lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

On Wed, Jun 15, 2011 at 7:48 PM, Luiz Henrique de Figueiredo
<> wrote:
>> Lua 5.2 has also broken my code (not scripts but C/C++ and runtime )
>> too in a more fundamental level, but I managed to solve it to support
>> lua 5.2...
> Please share your problems here if they may help other people moving from 5.1
> to 5.2.

1) the LUA_GLOBALSINDEX and environments (setfenv, getfenv) was a
major change for me. I used a lot in SLB (Simple Lua Binder), that
change forced to use a complete different approach.

2) the last update 5.2-beta introduce a funny behavior with __gc. Now
you need to setup a metatable with the __gc entry before the metatable
is used with an user_data (or it won't be called). And also now __gc
is called for tables, which didn't happen before (in my code I always
try to pick a user data as first argument, and suddenly a table appear
where user_data used to be)

apart from that the change was pretty much straightforward.


  Jose L. Hidalgo Valiño (PpluX)
  ---- ----