From: Stefan Behnel Date: Fri, 19 Dec 2008 02:03:16 +0000 (+0100) Subject: work around for earlier compile error X-Git-Tag: 0.11-beta~111 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=185235d2cc39d4a32978f76e7cd34b3302f961ae;p=cython.git work around for earlier compile error --- diff --git a/Cython/Compiler/ParseTreeTransforms.py b/Cython/Compiler/ParseTreeTransforms.py index 9e383806..2e7bb061 100644 --- a/Cython/Compiler/ParseTreeTransforms.py +++ b/Cython/Compiler/ParseTreeTransforms.py @@ -634,9 +634,10 @@ class ComprehensionTransform(VisitorTransform): return node def visit_NameNode(self, node): - replacement = self.comprehension_targets.get(node.entry.cname) - if replacement is not None: - return replacement + if node.entry: + replacement = self.comprehension_targets.get(node.entry.cname) + if replacement is not None: + return replacement return node