fix annotation of optimised switch statement
authorStefan Behnel <scoder@users.berlios.de>
Sat, 14 Mar 2009 17:12:20 +0000 (18:12 +0100)
committerStefan Behnel <scoder@users.berlios.de>
Sat, 14 Mar 2009 17:12:20 +0000 (18:12 +0100)
Cython/Compiler/Nodes.py

index 4c8224a8416fad8acc7d8b92989fbdd8cc561844..a23d30979b4ac4ba5a8ed034eff3695c208e02ed 100644 (file)
@@ -3692,6 +3692,7 @@ class SwitchCaseNode(StatNode):
     
     def generate_execution_code(self, code):
         for cond in self.conditions:
+            code.mark_pos(cond.pos)
             code.putln("case %s:" % cond.calculate_result_code())
         self.body.generate_execution_code(code)
         code.putln("break;")