fix IndexNode.is_simple() for buffer access
authorStefan Behnel <scoder@users.berlios.de>
Fri, 28 Jan 2011 18:04:49 +0000 (19:04 +0100)
committerStefan Behnel <scoder@users.berlios.de>
Fri, 28 Jan 2011 18:04:49 +0000 (19:04 +0100)
Cython/Compiler/ExprNodes.py

index 5c4c0579283adc8e3229f0aa5ab99981ce88e06e..965c9b49394477bda22bc4ff5094f7f17fcf03c2 100755 (executable)
@@ -2015,6 +2015,8 @@ class IndexNode(ExprNode):
         return self.base.is_ephemeral()
 
     def is_simple(self):
+        if self.is_buffer_access:
+            return False
         base = self.base
         return (base.is_simple() and self.index.is_simple()
                 and base.type and (base.type.is_ptr or base.type.is_array))