summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Florenzano <floguy@gmail.com>2009-10-29 02:31:19 -0700
committerEric Florenzano <floguy@gmail.com>2009-10-29 02:31:19 -0700
commit126757068ea6466f6d61c7c4e3f4095f5aa4bec8 (patch)
tree42bb14a4c44874ee0b7567f2793d2212af5659c5
parenta28576f6d1550e84da1f3851d8847c6d059b7c4b (diff)
downloadpystache-126757068ea6466f6d61c7c4e3f4095f5aa4bec8.tar.gz
Get rid of vestigial regexes
-rw-r--r--pystache/template.py4
1 files changed, 0 insertions, 4 deletions
diff --git a/pystache/template.py b/pystache/template.py
index 4016515..584a5fe 100644
--- a/pystache/template.py
+++ b/pystache/template.py
@@ -23,9 +23,7 @@ class Template(object):
def render_sections(self, template, context):
"""Expands sections."""
- regexp = re.compile(r"{{\#([^\}]*)}}\s*(.+?)\s*{{/\1}}", re.M | re.S)
match = SECTION_RE.search(template)
-
while match:
section, section_name, inner = match.group(0, 1, 2)
if section_name in context and context[section_name]:
@@ -46,8 +44,6 @@ class Template(object):
def render_tags(self, template, context):
"""Renders all the tags in a template for a context."""
- regexp = re.compile(r"{{(#|=|!|<|>|\{)?(.+?)\1?}}+")
-
match = TAG_RE.search(template)
while match:
tag, tag_type, tag_name = match.group(0, 1, 2)