[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Lua vs LuaJIT, compatibility on GC behaviour for weak tables
- From: Francesco Abbate <francesco.bbt@...>
- Date: Tue, 1 Feb 2011 18:19:33 +0100
Hi all,
I've a question about Lua/LuaJIT compatiblity. As you know Lua have a
very peculiar behaviour when you have a table with weak keys and the
key is un userdata. In this case the key object can be finalized but
not immediately removed from the table. It will be removed only at the
next GC cycle.
See:
http://lua-users.org/lists/lua-l/2010-08/msg00605.html
As this behaviour is undocumented in Lua 5.1.4 I was wondering if
LuaJIT is doing exactly the same thing of Lua. For me is important
because if LuaJIT is doing the same I will need to implement a
workaround in my code.
Thanks in advance for any help.
Best regards,
Francesco