mirror of
https://github.com/python/cpython.git
synced 2025-08-22 17:55:18 +00:00
bpo-39573: Clean up modules and headers to use Py_IS_TYPE() function (GH-18521)
This commit is contained in:
parent
a7847590f0
commit
1b55b65638
33 changed files with 56 additions and 56 deletions
|
@ -13,9 +13,9 @@
|
|||
#include "pycore_accu.h"
|
||||
|
||||
#define PyScanner_Check(op) PyObject_TypeCheck(op, &PyScannerType)
|
||||
#define PyScanner_CheckExact(op) (Py_TYPE(op) == &PyScannerType)
|
||||
#define PyScanner_CheckExact(op) Py_IS_TYPE(op, &PyScannerType)
|
||||
#define PyEncoder_Check(op) PyObject_TypeCheck(op, &PyEncoderType)
|
||||
#define PyEncoder_CheckExact(op) (Py_TYPE(op) == &PyEncoderType)
|
||||
#define PyEncoder_CheckExact(op) Py_IS_TYPE(op, &PyEncoderType)
|
||||
|
||||
static PyTypeObject PyScannerType;
|
||||
static PyTypeObject PyEncoderType;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue