mirror of
https://github.com/python/cpython.git
synced 2025-11-03 03:22:27 +00:00
Issue #7105: Make WeakKeyDictionary and WeakValueDictionary robust against
the destruction of weakref'ed objects while iterating.
This commit is contained in:
parent
dc2a61347b
commit
c1baa601e2
6 changed files with 296 additions and 56 deletions
|
|
@ -159,7 +159,7 @@ than needed.
|
|||
|
||||
.. method:: WeakKeyDictionary.keyrefs()
|
||||
|
||||
Return an :term:`iterator` that yields the weak references to the keys.
|
||||
Return an iterable of the weak references to the keys.
|
||||
|
||||
|
||||
.. class:: WeakValueDictionary([dict])
|
||||
|
|
@ -182,7 +182,7 @@ These method have the same issues as the and :meth:`keyrefs` method of
|
|||
|
||||
.. method:: WeakValueDictionary.valuerefs()
|
||||
|
||||
Return an :term:`iterator` that yields the weak references to the values.
|
||||
Return an iterable of the weak references to the values.
|
||||
|
||||
|
||||
.. class:: WeakSet([elements])
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue