summaryrefslogtreecommitdiffstats
path: root/Misc
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>2002-06-04 19:52:53 (GMT)
committerGuido van Rossum <guido@python.org>2002-06-04 19:52:53 (GMT)
commit9923ffe2c0f96b1b79f2f5ae39b64b55e038c566 (patch)
tree7449f4009ac1d95cac9185ebad1d2d622546c708 /Misc
parente22bc1e84135765456dee6337e6e6f61245aa694 (diff)
downloadcpython-9923ffe2c0f96b1b79f2f5ae39b64b55e038c566.zip
cpython-9923ffe2c0f96b1b79f2f5ae39b64b55e038c566.tar.gz
cpython-9923ffe2c0f96b1b79f2f5ae39b64b55e038c566.tar.bz2
Address SF bug 519621: slots weren't traversed by GC.
While I was at it, I added a tp_clear handler and changed the tp_dealloc handler to use the clear_slots helper for the tp_clear handler. Also tightened the rules for slot names: they must now be proper identifiers (ignoring the dirty little fact that <ctype.h> is locale sensitive). Also set mp->flags = READONLY for the __weakref__ pseudo-slot. Most of this is a 2.2 bugfix candidate; I'll apply it there myself.
Diffstat (limited to 'Misc')
-rw-r--r--Misc/NEWS6
1 files changed, 6 insertions, 0 deletions
diff --git a/Misc/NEWS b/Misc/NEWS
index e534317..ce2b09a 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -6,6 +6,12 @@ Type/class unification and new-style classes
Core and builtins
+- Classes using __slots__ are now properly garbage collected.
+ [SF bug 519621]
+
+- Tightened the __slots__ rules: a slot name must be a valid Python
+ identifier.
+
- The constructor for the module type now requires a name argument and
takes an optional docstring argument. Previously, this constructor
ignored its arguments. As a consequence, deriving a class from a