cpython: 96d1207d33d0 (original) (raw)

Mercurial > cpython

changeset 87652:96d1207d33d0 3.3

Issue #19088: Fix incorrect caching of the copyreg module. This fix does not cause any degradation in performance. [#19088]

Alexandre Vassalotti alexandre@peadrop.com
date Sat, 30 Nov 2013 00:53:09 -0800
parents 63f3e8670fa6
children 1ceb6f84b617 b92f9eaedb76
files Misc/NEWS Objects/typeobject.c
diffstat 2 files changed, 26 insertions(+), 20 deletions(-)[+] [-] Misc/NEWS 3 Objects/typeobject.c 43

line wrap: on

line diff

--- a/Misc/NEWS +++ b/Misc/NEWS @@ -18,6 +18,9 @@ Core and Builtins Library ------- +- Issue #19088: Fixed incorrect caching of the copyreg module in

--- a/Objects/typeobject.c +++ b/Objects/typeobject.c @@ -7,10 +7,6 @@ #include <ctype.h> -/* Cached lookup of the copyreg module, for faster reduce calls */ - -static PyObject cached_copyreg_module = NULL; - / Support type attribute cache / / The cache can keep references to the names alive for longer than @@ -73,9 +69,6 @@ void _PyType_Fini(void) { PyType_ClearCache();

} void @@ -3348,19 +3341,29 @@ static PyGetSetDef object_getsets[] = { static PyObject * import_copyreg(void) {

-

-

+

} static PyObject *