Fix any/all.
authorRobert Bradshaw <robertwb@math.washington.edu>
Tue, 14 Dec 2010 04:31:48 +0000 (20:31 -0800)
committerRobert Bradshaw <robertwb@math.washington.edu>
Tue, 14 Dec 2010 04:31:48 +0000 (20:31 -0800)
Cython/Compiler/ExprNodes.py

index de026275b0a92519ed813ef4c136d3d13f8bb95b..cea32d7bd44615c4733aec0eead9ef5a0d921db6 100755 (executable)
@@ -3401,7 +3401,7 @@ class AttributeNode(ExprNode):
             return module_scope.lookup_type(self.attribute)
         if not isinstance(self.obj, (UnicodeNode, StringNode, BytesNode)):
             base_type = self.obj.analyse_as_type(env)
-            if base_type and hasattr(base_type, 'scope'):
+            if base_type and hasattr(base_type, 'scope') and base_type.scope is not None:
                 return base_type.scope.lookup_type(self.attribute)
         return None