[issue22453] PyObject_REPR macro causes refcount leak

2014-09-21 Thread Chris Colbert
New submission from Chris Colbert: This is how the macro is defined in object.h: 2.7 /* Helper for passing objects to printf and the like */ #define PyObject_REPR(obj) PyString_AS_STRING(PyObject_Repr(obj)) 3.4 /* Helper for passing objects to printf and the like */ #define PyObject_REPR(obj

[issue16272] C-API documentation clarification for tp_dictoffset

2012-10-17 Thread Chris Colbert
New submission from Chris Colbert: The documentation of the tp_dictoffset is a bit unclear when describing the responsibilities of a base type with a nonzero tp_dictoffset. http://docs.python.org/c-api/typeobj.html I feel there should some statement to the effect of: """ If a

[issue11628] cmp_to_key generated class should use __slots__

2011-03-21 Thread Chris Colbert
Chris Colbert added the comment: Man, you guys are quick! Cheers! -- ___ Python tracker <http://bugs.python.org/issue11628> ___ ___ Python-bugs-list mailin

[issue11628] cmp_to_key generated class should use __slots__

2011-03-21 Thread Chris Colbert
New submission from Chris Colbert : The cmp_to_key func acts as a class factory for generating key objects that behave according to a user defined cmp function. Many patterns/libs that make use of key functions (for example blist and the SortedCollection recipe) store the the results of the