lua-users home
lua-l archive

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

Hello Dmitry,

Monday, June 8, 2009, 11:16:42 PM, you wrote:

> Any approaches to this problem?

add extra level of indirection. objects manipulated by Lua code are
never explicitly destroyed, they just collected by GC. these objects
are just pointers to real Foo. unfoo() sets this pointer to NULL

or, if you don't need manual Foo lifetime control, just call unfoo()
in GC

Best regards,