Pass on free_temps also through non-temp ExprNodes
authorDag Sverre Seljebotn <dagss@student.matnat.uio.no>
Sun, 18 Jan 2009 11:47:45 +0000 (12:47 +0100)
committerDag Sverre Seljebotn <dagss@student.matnat.uio.no>
Sun, 18 Jan 2009 11:47:45 +0000 (12:47 +0100)
Cython/Compiler/ExprNodes.py

index d500d7a059d272f9d4c85d1f8fd74f76ea7d3534..fa9f6ea3b60ae904c84e0d6fceca6df583ed423c 100644 (file)
@@ -510,7 +510,9 @@ class ExprNode(Node):
         pass
 
     def free_temps(self, code):
-        pass
+        if not self.is_temp:
+            self.free_subexpr_temps(code)
+        # otherwise, already freed in generate_evaluation_code
     
     def free_subexpr_temps(self, code):
         for sub in self.subexpr_nodes():