diff Include/objimpl.h @ 39222:b0cdcbcc5f45

Get rid of most of the flags (in tp_flags) that keep track of various variations of the type struct and its attachments. In Py3k, all type structs have to have all fields -- no binary backwards compatibility. Had to change the complex object to a new-style number!
author Guido van Rossum <guido@python.org>
date Thu, 27 Jul 2006 21:53:35 +0000
parents f731859e9b3b
children e70cdce0e8b2
line wrap: on
line diff
--- a/Include/objimpl.h	Thu Jun 08 15:35:45 2006 +0000
+++ b/Include/objimpl.h	Thu Jul 27 21:53:35 2006 +0000
@@ -323,9 +323,7 @@
 
 
 /* Test if a type supports weak references */
-#define PyType_SUPPORTS_WEAKREFS(t) \
-        (PyType_HasFeature((t), Py_TPFLAGS_HAVE_WEAKREFS) \
-         && ((t)->tp_weaklistoffset > 0))
+#define PyType_SUPPORTS_WEAKREFS(t) ((t)->tp_weaklistoffset > 0)
 
 #define PyObject_GET_WEAKREFS_LISTPTR(o) \
 	((PyObject **) (((char *) (o)) + (o)->ob_type->tp_weaklistoffset))