lua-users home
lua-l archive

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

Ariel Manzur wrote:

> You have a table with a __gc metamethod and that works? is that a new 5.1 
> thing?

I apologize first that I did not follow this thread more carefully.

Second, you are absolutely correct that this does not work for tables. I
don't know why I never noticed it. I was so happy long ago that it
worked with userdata that I assumed that it also worked with tables, and
when I switched methods I never even considered that the "__gc"
metamethod would not be invoked for collected tables.

I've looked back through my code repository and see that I did not even
check in the version with userdata. My Lua code is used for interactive
test purposes and not for our customers. I did not notice the loss in



Doug Rogers - ICI - V:703.893.2007x220