Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 77ebfcc + 9439f04 commit 609939eCopy full SHA for 609939e
1 file changed
Doc/library/weakref.rst
@@ -24,7 +24,10 @@ by a weak reference.
24
A weak reference to an object is not enough to keep the object alive: when the
25
only remaining references to a referent are weak references,
26
:term:`garbage collection` is free to destroy the referent and reuse its memory
27
-for something else. A primary use for weak references is to implement caches or
+for something else. However, until the object is actually destroyed the weak
28
+reference may return the object even if there are no strong references to it.
29
+
30
+A primary use for weak references is to implement caches or
31
mappings holding large objects, where it's desired that a large object not be
32
kept alive solely because it appears in a cache or mapping.
33
0 commit comments