summaryrefslogtreecommitdiff
path: root/pystache/renderengine.py
diff options
context:
space:
mode:
authorChris Jerdonek <chris.jerdonek@gmail.com>2011-12-22 00:24:20 -0800
committerChris Jerdonek <chris.jerdonek@gmail.com>2011-12-22 00:24:20 -0800
commit9eab209c6f9c4197a79c70ff8c1dcf1f7785e45a (patch)
treef7c40638c26bddf0dc3d4ddac027f94f0456e170 /pystache/renderengine.py
parentf6f24cbf06ec323566153f2ce57e416c794e40cd (diff)
downloadpystache-9eab209c6f9c4197a79c70ff8c1dcf1f7785e45a.tar.gz
Fixed issue #33 (via fczuardi): "multiline comments not working"
See https://github.com/defunkt/pystache/issues/33
Diffstat (limited to 'pystache/renderengine.py')
-rw-r--r--pystache/renderengine.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/pystache/renderengine.py b/pystache/renderengine.py
index b0b797c..c08dad1 100644
--- a/pystache/renderengine.py
+++ b/pystache/renderengine.py
@@ -106,7 +106,8 @@ class RenderEngine(object):
self.section_re = re.compile(section, re.M|re.S)
tag = r"%(otag)s(#|=|&|!|>|\{)?(.+?)\1?%(ctag)s+" % tags
- self.tag_re = re.compile(tag)
+ # We use re.DOTALL to permit multiline comments, in accordance with the spec.
+ self.tag_re = re.compile(tag, re.DOTALL)
def _render_tags(self, template):
output = []