Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
f475729a
Commit
f475729a
authored
Jun 15, 2019
by
Géry Ogam
Committed by
Miss Islington (bot)
Jun 15, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update weakref.rst (GH-14098)
parent
0237265e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
5 deletions
+6
-5
Doc/library/weakref.rst
Doc/library/weakref.rst
+6
-5
No files found.
Doc/library/weakref.rst
View file @
f475729a
...
...
@@ -65,8 +65,8 @@ exposed by the :mod:`weakref` module for the benefit of advanced uses.
Not all objects can be weakly referenced; those objects which can include class
instances, functions written in Python (but not in C), instance methods, sets,
frozensets, some :term:`file objects <file object>`, :term:`generator
`\s, type
objects, sockets, arrays, deques, regular expression pattern objects, and code
frozensets, some :term:`file objects <file object>`, :term:`generator
s <generator>`,
type
objects, sockets, arrays, deques, regular expression pattern objects, and code
objects.
.. versionchanged:: 3.2
...
...
@@ -80,9 +80,10 @@ support weak references but can add support through subclassing::
obj = Dict(red=1, green=2, blue=3) # this object is weak referenceable
Other built-in types such as :class:`tuple` and :class:`int` do not support weak
references even when subclassed (This is an implementation detail and may be
different across various Python implementations.).
.. impl-detail::
Other built-in types such as :class:`tuple` and :class:`int` do not support weak
references even when subclassed.
Extension types can easily be made to support weak references; see
:ref:`weakref-support`.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment