Commits

Mike Bayer committed 70f561b

- [bug] Fixed issue where an old lexer rule prevented a template line
which looked like "#*" from being correctly parsed. [ticket:224]

Comments (0)

Files changed (3)

   instead of ``# -*- encoding:%s -*-``; the former is more common
   and compatible with emacs.  Courtesy Martin Geisler.
 
+- [bug] Fixed issue where an old lexer rule prevented a template line
+  which looked like "#*" from being correctly parsed.  [ticket:224]
+
 0.9.0
 - [bug] The Context.locals_() method becomes a private underscored
   method, as this method has a specific internal use. The purpose
                  |
                  (?=\${)      # an expression
                  |
-                 (?=\#\*)     # multiline comment
-                 |
                  (?=</?[%&])  # a substitution or block or call start or end
                               # - don't consume
                  |

test/test_lexer.py

                       ControlLine('if', 'endif', True, (7, 1)),
                       Text('        ', (8, 1))]))
 
+    def test_old_multiline_comment(self):
+        template = """#*"""
+        node = Lexer(template).parse()
+        self._compare(node, TemplateNode({}, [Text('''#*''', (1, 1))]))
+
+
     def test_text_tag(self):
         template = \
             """