On Fri, 25 May 2012 10:21:39 -0700
Ethan Furman <et...@stoneleaf.us> wrote:
> I'd like to make a slight doc change for weakref to state (more or less):
> 
>     weakrefs are not invalidated when the strong refs
>     are gone, but rather when garbage collection
>     reclaims the object
> 
> Should this be accurate for all implementations, or should it be more 
> along the lines of:
> 
>     weakrefs may be invalidated as soon as the strong refs
>     are gone, but may last until garbage collection reclaims
>     the object

How about: weakrefs are invalidated when the object is destroyed,
either as a product of all the strong references being gone or the
object being reclaimed by the :term:`cyclic garbage collector
<garbage collection>`.

Regards

Antoine.


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

Reply via email to