From a8599e8bb2cc109ffb932b70f4565a94da6ab425 Mon Sep 17 00:00:00 2001 From: Brian Crowell Date: Sun, 21 Oct 2012 11:36:47 -0500 Subject: [PATCH] py3k: Remove ancient Python hacks --- _imagingcms.c | 5 ----- _imagingft.c | 9 --------- decode.c | 5 ----- display.c | 5 ----- encode.c | 5 ----- map.c | 5 ----- outline.c | 5 ----- path.c | 14 -------------- 8 files changed, 53 deletions(-) diff --git a/_imagingcms.c b/_imagingcms.c index 65958f33a..6b215cabb 100644 --- a/_imagingcms.c +++ b/_imagingcms.c @@ -28,11 +28,6 @@ http://www.cazabon.com\n\ #include "Imaging.h" #include "py3.h" -#if PY_VERSION_HEX < 0x01060000 -#define PyObject_New PyObject_NEW -#define PyObject_Del PyMem_DEL -#endif - #if LCMS_VERSION < 117 #define LCMSBOOL BOOL #endif diff --git a/_imagingft.c b/_imagingft.c index 864d74033..f54e38553 100644 --- a/_imagingft.c +++ b/_imagingft.c @@ -35,15 +35,6 @@ #include #endif -#if PY_VERSION_HEX < 0x01060000 -#define PyObject_New PyObject_NEW -#define PyObject_Del PyMem_DEL -#endif - -#if !defined(Py_RETURN_NONE) -#define Py_RETURN_NONE return Py_INCREF(Py_None), Py_None -#endif - #define KEEP_PY_UNICODE #include "py3.h" diff --git a/decode.c b/decode.c index 0b2be8dfd..9ecfee346 100644 --- a/decode.c +++ b/decode.c @@ -31,11 +31,6 @@ #include "Python.h" -#if PY_VERSION_HEX < 0x01060000 -#define PyObject_New PyObject_NEW -#define PyObject_Del PyMem_DEL -#endif - #include "Imaging.h" #include "py3.h" diff --git a/display.c b/display.c index 1ce537c64..3751b0a2b 100644 --- a/display.c +++ b/display.c @@ -25,11 +25,6 @@ #include "Python.h" -#if PY_VERSION_HEX < 0x01060000 -#define PyObject_New PyObject_NEW -#define PyObject_Del PyMem_DEL -#endif - #include "Imaging.h" #include "py3.h" diff --git a/encode.c b/encode.c index 670bd7dc9..479da7d51 100644 --- a/encode.c +++ b/encode.c @@ -24,11 +24,6 @@ #include "Python.h" -#if PY_VERSION_HEX < 0x01060000 -#define PyObject_New PyObject_NEW -#define PyObject_Del PyMem_DEL -#endif - #include "Imaging.h" #include "py3.h" #include "Gif.h" diff --git a/map.c b/map.c index cd3a8e43d..c9ad10914 100644 --- a/map.c +++ b/map.c @@ -20,11 +20,6 @@ #include "Python.h" -#if PY_VERSION_HEX < 0x01060000 -#define PyObject_New PyObject_NEW -#define PyObject_Del PyMem_DEL -#endif - #include "Imaging.h" #ifdef WIN32 diff --git a/outline.c b/outline.c index 46db7c938..25e63aeaf 100644 --- a/outline.c +++ b/outline.c @@ -19,11 +19,6 @@ #include "Python.h" -#if PY_VERSION_HEX < 0x01060000 -#define PyObject_New PyObject_NEW -#define PyObject_Del PyMem_DEL -#endif - #include "Imaging.h" diff --git a/path.c b/path.c index a27b59156..622edb10a 100644 --- a/path.c +++ b/path.c @@ -30,20 +30,6 @@ #include -#if PY_VERSION_HEX < 0x01060000 -#define PyObject_New PyObject_NEW -#define PyObject_Del PyMem_DEL -#endif - -#if PY_VERSION_HEX < 0x02050000 -#define Py_ssize_t int -#define lenfunc inquiry -#define ssizeargfunc intargfunc -#define ssizessizeargfunc intintargfunc -#define ssizeobjargproc intobjargproc -#define ssizessizeobjargproc intintobjargproc -#endif - #include "py3.h" /* compatibility wrappers (defined in _imaging.c) */