lua-users home
lua-l archive

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


On Tue, Dec 28, 2010 at 13:10, Elias Barrionovo <elias.tandel@gmail.com> wrote:
> But now, if you want to stop the GC after collectgarbage(), you can
> explicitly call collectgarbage"stop" .
> Perhaps the change would make it more logical, but i don't think it makes a
> lot of difference.
>
> Or does it?
>
> On Tue, Dec 28, 2010 at 5:20 PM, Patrick Rapin <toupie300@gmail.com> wrote:
>>
>> I do not use this feature.
>> In fact, I also find the current behavior very questionable: if
>> garbage collection is switched off, it might be because we want to run
>> garbage collection "manually" by explicitly calling collectgarbage().
>> So if this call re-enables automatic collection, this is clearly a
>> negative side effect.
>> The proposed solution is IMHO more logical and more handy. If one
>> wants a full collection *and* the automatic collection restarting, he
>> just has to make two separate calls.
>> By the way, I looked at the documentation and noticed that the
>> behavior of collectgarbage() while the garbage collector is off is not
>> described.
>>
>
>
>
> --
> NI!
>

It does seem like a gotcha. You disable it and run it manually, and
suddenly it's enabled again? Hey? You didn't enable it...

-- 
Sent from my toaster.