]> granicus.if.org Git - python/commitdiff
Add a flag to indicate the presence of the tp_richcompare field, and
authorGuido van Rossum <guido@python.org>
Wed, 24 Jan 2001 22:13:48 +0000 (22:13 +0000)
committerGuido van Rossum <guido@python.org>
Wed, 24 Jan 2001 22:13:48 +0000 (22:13 +0000)
add it to the default flags.

Include/object.h

index 050369191adebeedee646577ee5cbc6bd04ea4ab..de6750550abdfaf49ad3b33e6c49e45c1a367129 100644 (file)
@@ -337,9 +337,14 @@ given type object has a specified feature.
 /* PyNumberMethods do their own coercion */
 #define Py_TPFLAGS_CHECKTYPES (1L<<4)
 
-#define Py_TPFLAGS_DEFAULT  (Py_TPFLAGS_HAVE_GETCHARBUFFER | \
+#define Py_TPFLAGS_HAVE_RICHCOMPARE (1L<<5)
+
+#define Py_TPFLAGS_DEFAULT  ( \
+                             Py_TPFLAGS_HAVE_GETCHARBUFFER | \
                              Py_TPFLAGS_HAVE_SEQUENCE_IN | \
-                             Py_TPFLAGS_HAVE_INPLACEOPS)
+                             Py_TPFLAGS_HAVE_INPLACEOPS | \
+                             Py_TPFLAGS_HAVE_RICHCOMPARE | \
+                            0)
 
 #define PyType_HasFeature(t,f)  (((t)->tp_flags & (f)) != 0)