mirror of https://github.com/python/cpython.git
Move backwards compatibility macro to the correct place;
PyIndex_Check() was introduced in Python 2.5.
This commit is contained in:
parent
17f8429bd2
commit
12c4e6478a
|
@ -10,6 +10,7 @@
|
||||||
typedef int Py_ssize_t;
|
typedef int Py_ssize_t;
|
||||||
#define PyInt_FromSsize_t PyInt_FromLong
|
#define PyInt_FromSsize_t PyInt_FromLong
|
||||||
#define PyNumber_AsSsize_t(ob, exc) PyInt_AsLong(ob)
|
#define PyNumber_AsSsize_t(ob, exc) PyInt_AsLong(ob)
|
||||||
|
#define PyIndex_Check(ob) PyInt_Check(ob)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if (PY_VERSION_HEX < 0x02060000)
|
#if (PY_VERSION_HEX < 0x02060000)
|
||||||
|
@ -17,7 +18,6 @@ typedef int Py_ssize_t;
|
||||||
#define PyVarObject_HEAD_INIT(type, size) \
|
#define PyVarObject_HEAD_INIT(type, size) \
|
||||||
PyObject_HEAD_INIT(type) size,
|
PyObject_HEAD_INIT(type) size,
|
||||||
#define PyImport_ImportModuleNoBlock PyImport_ImportModule
|
#define PyImport_ImportModuleNoBlock PyImport_ImportModule
|
||||||
#define PyIndex_Check(ob) PyInt_Check(ob)
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue