[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Collecting dead strings
- From: "Research" <research@...>
- Date: Fri, 23 Jun 2006 18:03:17 +0800
Hi,
I need to know how to properly destroy my lua code when it's no longer
needed in my game engine.
If I have:
function f29d8()
-- some code
end
foo = f29d8
fooTable = t29d8
t29d8.scriptFunction = f29d8
Is setting f29d8 = nil and t29d8 = nil good enough to cause foo and fooTable
to be garbage collected if I call lua_setgcthreshold(L, 0)?
Or do I need to explicitly set each reference to nil too?
Thanks,
Brett