Giovanni Bajo wrote:

> Uh? If __dict__ contains a cycle back to the original object, then the object 
> is part of a cycle already, with or without getting an additional reference 
> to 
> the __dict__ within the finalization callback.

Yes, but storing a finalizer in a global registry that
references the __dict__ makes it an *immortal* cycle,
because the GC won't see it as an isolated cycle that's
not referenced from outside.

> And if there's no cycle, you're not creating one by just 
 > referencing __dict__.

It's not creation of the cycle that's the issue, it's
keeping it alive forever once it's created.

--
Greg
_______________________________________________
Python-3000 mailing list
Python-3000@python.org
http://mail.python.org/mailman/listinfo/python-3000
Unsubscribe: 
http://mail.python.org/mailman/options/python-3000/archive%40mail-archive.com

Reply via email to