Commit fc728e4a authored by Jeroen Demeyer's avatar Jeroen Demeyer

PyTypeObject members tp_compare, tp_richcompare, tp_base

parent 4b8c1991
......@@ -22,6 +22,9 @@ cdef extern from "Python.h":
ctypedef Py_hash_t (*hashfunc)(object)
ctypedef object (*reprfunc)(object)
ctypedef int (*cmpfunc)(object, object)
ctypedef object (*richcmpfunc)(object, object, int)
# The following functions use 'PyObject*' as first argument instead of 'object' to prevent
# accidental reference counting when calling them during a garbage collection run.
ctypedef void (*destructor)(PyObject*)
......@@ -46,6 +49,11 @@ cdef extern from "Python.h":
reprfunc tp_str
reprfunc tp_repr
cmpfunc tp_compare
richcmpfunc tp_richcompare
PyTypeObject* tp_base
ctypedef struct PyObject:
Py_ssize_t ob_refcnt
PyTypeObject *ob_type
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment