Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[backport to 3.5] bpo-29474: Improve documentation for weakref.WeakValueDictionary #23

Merged
merged 1 commit into from
Feb 12, 2017
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions Doc/library/weakref.rst
Original file line number Diff line number Diff line change
Expand Up @@ -166,8 +166,8 @@ Extension types can easily be made to support weak references; see
performed by the program during iteration may cause items in the
dictionary to vanish "by magic" (as a side effect of garbage collection).

:class:`WeakKeyDictionary` objects have the following additional methods. These
expose the internal references directly. The references are not guaranteed to
:class:`WeakKeyDictionary` objects have an additional method that
exposes the internal references directly. The references are not guaranteed to
be "live" at the time they are used, so the result of calling the references
needs to be checked before being used. This can be used to avoid creating
references that will cause the garbage collector to keep the keys around longer
Expand All @@ -192,9 +192,9 @@ than needed.
by the program during iteration may cause items in the dictionary to vanish "by
magic" (as a side effect of garbage collection).

:class:`WeakValueDictionary` objects have the following additional methods.
These method have the same issues as the and :meth:`keyrefs` method of
:class:`WeakKeyDictionary` objects.
:class:`WeakValueDictionary` objects have an additional method that has the
same issues as the :meth:`keyrefs` method of :class:`WeakKeyDictionary`
objects.


.. method:: WeakValueDictionary.valuerefs()
Expand Down