File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed
Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -19,7 +19,7 @@ typedef struct {
1919
2020PyAPI_DATA (PyTypeObject ) PyMethod_Type ;
2121
22- #define PyMethod_Check (op ) (Py_TYPE(op)== &PyMethod_Type)
22+ #define PyMethod_Check (op ) Py_IS_TYPE(op, &PyMethod_Type)
2323
2424PyAPI_FUNC (PyObject * ) PyMethod_New (PyObject * , PyObject * );
2525
@@ -40,7 +40,7 @@ typedef struct {
4040
4141PyAPI_DATA (PyTypeObject ) PyInstanceMethod_Type ;
4242
43- #define PyInstanceMethod_Check (op ) (Py_TYPE(op) == &PyInstanceMethod_Type)
43+ #define PyInstanceMethod_Check (op ) Py_IS_TYPE(op, &PyInstanceMethod_Type)
4444
4545PyAPI_FUNC (PyObject * ) PyInstanceMethod_New (PyObject * );
4646PyAPI_FUNC (PyObject * ) PyInstanceMethod_Function (PyObject * );
Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ extern "C" {
1212
1313PyAPI_DATA (PyTypeObject ) PyPickleBuffer_Type ;
1414
15- #define PyPickleBuffer_Check (op ) (Py_TYPE(op) == &PyPickleBuffer_Type)
15+ #define PyPickleBuffer_Check (op ) Py_IS_TYPE(op, &PyPickleBuffer_Type)
1616
1717/* Create a PickleBuffer redirecting to the given buffer-enabled object */
1818PyAPI_FUNC (PyObject * ) PyPickleBuffer_FromObject (PyObject * );
You can’t perform that action at this time.
0 commit comments