Py2.3 compatibility fix
authorLisandro Dalcin <dalcinl@gmail.com>
Wed, 17 Feb 2010 00:54:12 +0000 (21:54 -0300)
committerLisandro Dalcin <dalcinl@gmail.com>
Wed, 17 Feb 2010 00:54:12 +0000 (21:54 -0300)
Cython/Compiler/Parsing.py

index 3f545c10fb7fc5a89bd92cc47c93f6d87dd0711a..a1e6a2500f585e5b80f96b10e950f14d582fb336 100644 (file)
@@ -10,6 +10,13 @@ cython.declare(Nodes=object, ExprNodes=object, EncodedString=object)
 import os
 import re
 import sys
+
+try:
+    set
+except NameError:
+    # Python 2.3
+    from sets import Set as set
+
 from Cython.Compiler.Scanning import PyrexScanner, FileSourceDescriptor
 import Nodes
 import ExprNodes