Commit 0c7af76d authored by Robert Bradshaw's avatar Robert Bradshaw

Python 2.3 fix.

parent 6922922e
from glob import glob from glob import glob
import re, os, sys import re, os, sys
from cython import set
try:
set
except NameError:
# Python 2.3
from sets import Set as set
from distutils.extension import Extension from distutils.extension import Extension
......
import tempfile import tempfile
import sys, os, re, inspect import sys, os, re, inspect
from cython import set
try: try:
import hashlib import hashlib
......
...@@ -188,16 +188,12 @@ except NameError: # Py3 ...@@ -188,16 +188,12 @@ except NameError: # Py3
py_float = float py_float = float
py_complex = complex py_complex = complex
try: try:
# Python 3 set
from builtins import set, frozenset except NameError:
except ImportError: # Python 2.3
try: from sets import Set as set, ImmutableSet as frozenset
# Python 2.4+
from __builtin__ import set, frozenset
except ImportError:
# Py 2.3
from sets import Set as set, ImmutableSet as frozenset
# Predefined types # Predefined types
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment