diff options
author | Fred Drake <fdrake@acm.org> | 2001-03-22 18:26:47 (GMT) |
---|---|---|
committer | Fred Drake <fdrake@acm.org> | 2001-03-22 18:26:47 (GMT) |
commit | 4e262a963190b201578b0b5d972035b1637f6bd5 (patch) | |
tree | 8c1e035b25075b1fb03f71d101260984d58a0e7c /Misc | |
parent | 82f1480d63a43c2007460e8f186aba8d0fc4ce38 (diff) | |
download | cpython-4e262a963190b201578b0b5d972035b1637f6bd5.zip cpython-4e262a963190b201578b0b5d972035b1637f6bd5.tar.gz cpython-4e262a963190b201578b0b5d972035b1637f6bd5.tar.bz2 |
A small change to the C API for weakly-referencable types: Such types
must now initialize the extra field used by the weak-ref machinery to
NULL themselves, to avoid having to require PyObject_INIT() to check
if the type supports weak references and do it there. This causes less
work to be done for all objects (the type object does not need to be
consulted to check for the Py_TPFLAGS_HAVE_WEAKREFS bit).
Diffstat (limited to 'Misc')
-rw-r--r-- | Misc/NEWS | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -61,6 +61,12 @@ Python/C API - Py_BuildValue() now has a "D" conversion to create a Python complex number from a Py_complex C value. +- Extensions types which support weak references must now set the + field allocated for the weak reference machinery to NULL themselves; + this is done to avoid the cost of checking each object for having a + weakly referencable type in PyObject_INIT(), since most types are + not weakly referencable. + Distutils - the sdist command now writes a PKG-INFO file, as described in PEP 241, |