provide 'set' builtin type in 'cython' namespace to make it available in Py2.3
authorStefan Behnel <scoder@users.berlios.de>
Sun, 14 Mar 2010 10:59:07 +0000 (11:59 +0100)
committerStefan Behnel <scoder@users.berlios.de>
Sun, 14 Mar 2010 10:59:07 +0000 (11:59 +0100)
Cython/Shadow.py

index 63269ca39376abb740303b46c72b44ff15d08862..6b638d73c2deaaa0fa588792dd42107e2f7f942c 100644 (file)
@@ -160,6 +160,12 @@ try:
 except NameError: # Py3
     py_long = int
 
+try:
+    set = __builtins__.set
+except AttributeError:
+    # Py 2.3
+    from sets import Set as set
+
 
 # Predefined types