diff options
author | R David Murray <rdmurray@bitdance.com> | 2014-01-06 21:32:05 (GMT) |
---|---|---|
committer | R David Murray <rdmurray@bitdance.com> | 2014-01-06 21:32:05 (GMT) |
commit | a101bdb88c064c77e7322063fac1a2f24a60b32b (patch) | |
tree | b49ce57c2c37f0f7b5cb24baa93561c794da9c34 /Doc/library/weakref.rst | |
parent | 983582759366b9135f100e60120678c2dbc00c83 (diff) | |
download | cpython-a101bdb88c064c77e7322063fac1a2f24a60b32b.zip cpython-a101bdb88c064c77e7322063fac1a2f24a60b32b.tar.gz cpython-a101bdb88c064c77e7322063fac1a2f24a60b32b.tar.bz2 |
whatsnew: ssl getpeercert/do_handshake raise OSError, weakref __callback__.
Also add a missing word to gc entry, and delete a now-obsolete doc note
in the weakref __callback__ docs. (Opened an issue for rewriting
the section that compares finalizers and __del__ method.)
Diffstat (limited to 'Doc/library/weakref.rst')
-rw-r--r-- | Doc/library/weakref.rst | 11 |
1 files changed, 1 insertions, 10 deletions
diff --git a/Doc/library/weakref.rst b/Doc/library/weakref.rst index e84ac2b..9ca60a9 100644 --- a/Doc/library/weakref.rst +++ b/Doc/library/weakref.rst @@ -123,15 +123,6 @@ Extension types can easily be made to support weak references; see weakref. If there is no callback or if the referent of the weakref is no longer alive then this attribute will have value ``None``. - .. note:: - - Like :meth:`__del__` methods, weak reference callbacks can be - called during interpreter shutdown when module globals have been - overwritten with :const:`None`. This can make writing robust - weak reference callbacks a challenge. Callbacks registered - using :class:`finalize` do not have to worry about this issue - because they will not be run after module teardown has begun. - .. versionchanged:: 3.4 Added the :attr:`__callback__` attribute. @@ -247,7 +238,7 @@ These method have the same issues as the and :meth:`keyrefs` method of .. class:: finalize(obj, func, *args, **kwargs) Return a callable finalizer object which will be called when *obj* - is garbage collected. Unlike an ordinary weak reference, a finalizer is + is garbage collected. Unlike an ordinary weak reference, a finalizer will always survive until the reference object is collected, greatly simplifying lifecycle management. |