bugfix: avoid emitting code that closes a comment in the annotation comment
authorThomas Hunger <hto@arcor.de>
Tue, 9 Oct 2007 15:20:56 +0000 (17:20 +0200)
committerThomas Hunger <hto@arcor.de>
Tue, 9 Oct 2007 15:20:56 +0000 (17:20 +0200)
Cython/Compiler/Code.py

index b22788498ee4db5c881d37ddd191d28df2b07b00..7c54d6ffe41af42b5a6a6044e8491a2160833c8c 100644 (file)
@@ -85,7 +85,8 @@ class CCodeWriter:
         try:
             return self.input_file_contents[file]
         except KeyError:
-            F = open(file).readlines()
+            F = [line.replace('*/', '*[inserted by cython to avoid comment closer]/')
+                 for line in open(file).readlines()]
             self.input_file_contents[file] = F
             return F