lua-users home
lua-l archive

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

Actually this idea will not work as possible cyclical references would not be collected as it's pointed by other posters. 


>-----Original Message-----
>From: Bilyk, Alex []
>Sent: Wednesday, June 09, 2004 5:40 PM
>To: Lua list
>Subject: RE: Feature request: more integration of Lua and C memory

>The idea of using an array of objects associated with user 
>data can be implemented via a table. Just create a vector 
>table, get a reference to it and store that reference in 
>userdata. On userdata GC you would either release this table's 
>reference or clean it up if there is a need to pool such 
>tables for reuse.