fix node type of EvalWithTempExprNode (when created after type analysis)
authorStefan Behnel <scoder@users.berlios.de>
Sun, 6 Dec 2009 13:49:36 +0000 (14:49 +0100)
committerStefan Behnel <scoder@users.berlios.de>
Sun, 6 Dec 2009 13:49:36 +0000 (14:49 +0100)
Cython/Compiler/UtilNodes.py

index 8e6029dde20f9ffec1c2a049189792e9e50342a4..071a75f852b30733e1edf9a13b239a1fe30136d6 100644 (file)
@@ -194,6 +194,8 @@ class EvalWithTempExprNode(ExprNodes.ExprNode, LetNodeMixin):
         self.set_temp_expr(lazy_temp)
         self.pos = subexpression.pos
         self.subexpression = subexpression
+        # if called after type analysis, we already know the type here
+        self.type = self.subexpression.type
 
     def infer_type(self, env):
         return self.subexpression.infer_type(env)