guile-devel
[Top][All Lists]
Advanced

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

Re: module GC bug


From: Han-Wen Nienhuys
Subject: Re: module GC bug
Date: Fri, 08 Jul 2005 23:43:59 +0200
User-agent: Mozilla Thunderbird 1.0.2-6 (X11/20050513)

Marius Vollmer wrote:

So the closure is a key in a weak hash-table, pointing to the module
as a value (using scm_stand_in_procs), the module is always marked
during GC. However, since the module points back to the closure via
the 'eval-closure slot, the key is always marked. Consequently,
neither closure nor module are ever GC'd.

I've fixed this by introducing a new function (eval-closure-module)
which returns the module of a closure via the eval-closure smob.


I think the right fix is to change the weak hashtable marking
algorithm to properly cope with circular references like this.  I will
try this and then come back to you.

Interesting. How would you go about doing that?


--
 Han-Wen Nienhuys - address@hidden - http://www.xs4all.nl/~hanwen




reply via email to

[Prev in Thread] Current Thread [Next in Thread]