summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRalf Schmitt <ralf@systemexit.de>2014-01-15 23:09:59 +0100
committerRalf Schmitt <ralf@systemexit.de>2014-01-15 23:09:59 +0100
commitcbd0f10631da723e81cf57c5ef747f34155fbc3e (patch)
treecd6729f2b846697358a8cfced271909832db1a2f
parent9484c509f14aa6f375d3fe15c52b3119109950b8 (diff)
downloadgreenlet-cbd0f10631da723e81cf57c5ef747f34155fbc3e.tar.gz
drop support for python 2.3
this allows us to delete a few lines.
-rw-r--r--greenlet.c22
-rw-r--r--tests/__init__.py12
2 files changed, 1 insertions, 33 deletions
diff --git a/greenlet.c b/greenlet.c
index 71434ee..c99f13f 100644
--- a/greenlet.c
+++ b/greenlet.c
@@ -76,28 +76,6 @@ The running greenlet's stack_start is undefined but not NULL.
using the dictionary key 'ts_curkey'.
*/
-/* Python 2.3 support */
-#ifndef Py_VISIT
-#define Py_VISIT(o) \
- if (o) { \
- int err; \
- if ((err = visit((PyObject *)(o), arg))) { \
- return err; \
- } \
- }
-#endif /* !Py_VISIT */
-
-#ifndef Py_CLEAR
-#define Py_CLEAR(op) \
- do { \
- if (op) { \
- PyObject *tmp = (PyObject *)(op); \
- (op) = NULL; \
- Py_DECREF(tmp); \
- } \
- } while (0)
-#endif /* !Py_CLEAR */
-
/* Python <= 2.5 support */
#if PY_MAJOR_VERSION < 3
#ifndef Py_REFCNT
diff --git a/tests/__init__.py b/tests/__init__.py
index 6de0dde..eb1c2e5 100644
--- a/tests/__init__.py
+++ b/tests/__init__.py
@@ -1,17 +1,7 @@
import os
import glob
import unittest
-
-try:
- unittest.TestCase.assertTrue
- unittest.TestCase.assertFalse
-except AttributeError:
- # monkey patch for Python 2.3 compatibility
- unittest.TestCase.assertTrue = unittest.TestCase.failUnless
- unittest.TestCase.assertFalse = unittest.TestCase.failIf
-
-from distutils.core import setup
-from distutils.core import Extension
+from distutils.core import setup, Extension
TEST_EXTENSIONS = [
Extension('_test_extension',