From: Robert Bradshaw Date: Sat, 11 Dec 2010 10:31:25 +0000 (-0800) Subject: another fix X-Git-Tag: 0.14.rc0~1 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=2e99b2363cc909943489383b1f1687c64037e65a;p=cython.git another fix --- diff --git a/Cython/Shadow.py b/Cython/Shadow.py index 0e22be6b..ddfb3fc5 100644 --- a/Cython/Shadow.py +++ b/Cython/Shadow.py @@ -190,10 +190,15 @@ py_complex = complex try: - set -except NameError: - # Python 2.3 - from sets import Set as set, ImmutableSet as frozenset + # Python 3 + from builtins import set, frozenset +except ImportError: + try: + # Python 2.4+ + from __builtin__ import set, frozenset + except ImportError: + # Py 2.3 + from sets import Set as set, ImmutableSet as frozenset # Predefined types