Skip to content

Commit 7f9b890

Browse files
committed
GH-157724: Fix external gc.rst outdated gc.is_tracked({}) value for GH-127010
it appears that since at least GH-127010 in 3.14 `gc.is_tracked({})` has returned `true`, but as of https://github.com/python/cpython/blob/9232c21a1c1eb6a12b96acebbef6c86a698228e0/Doc/library/gc.rst?plain=1#L205 the external GC documentation was not updated for this while the internal documentation, e.g. https://github.com/python/cpython/blob/9232c21a1c1eb6a12b96acebbef6c86a698228e0/InternalDocs/garbage_collector.md?plain=1#L726 was, so I update the external to be consistent here.
1 parent 6d4c6bf commit 7f9b890

1 file changed

Lines changed: 2 additions & 3 deletions

File tree

‎Doc/library/gc.rst‎

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -193,8 +193,7 @@ The :mod:`!gc` module provides the following functions:
193193
``False`` otherwise. As a general rule, instances of atomic types aren't
194194
tracked and instances of non-atomic types (containers, user-defined
195195
objects...) are. However, some type-specific optimizations can be present
196-
in order to suppress the garbage collector footprint of simple instances
197-
(e.g. dicts containing only atomic keys and values)::
196+
in order to suppress the garbage collector footprint of simple instances::
198197

199198
>>> gc.is_tracked(0)
200199
False
@@ -203,7 +202,7 @@ The :mod:`!gc` module provides the following functions:
203202
>>> gc.is_tracked([])
204203
True
205204
>>> gc.is_tracked({})
206-
False
205+
True
207206
>>> gc.is_tracked({"a": 1})
208207
True
209208

0 commit comments

Comments
 (0)