From 6d84be35ec6c17309a7c43f2dca20dd1bcc7d311 Mon Sep 17 00:00:00 2001 From: Armin Ronacher Date: Fri, 23 Mar 2007 16:58:36 +0100 Subject: [PATCH] [svn] and delete jinja 1.0 again. python2.3 bug --HG-- branch : trunk --- jinja/lexer.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/jinja/lexer.py b/jinja/lexer.py index d419c03..9b73e18 100644 --- a/jinja/lexer.py +++ b/jinja/lexer.py @@ -23,7 +23,7 @@ string_re = re.compile(r"('([^'\\]*(?:\\.[^'\\]*)*)'" r'|"([^"\\]*(?:\\.[^"\\]*)*)")(?ms)') number_re = re.compile(r'\d+(\.\d+)*') -operator_re = re.compile('(%s)' % '|'.join( +operator_re = re.compile('(%s)' % '|'.join([ isinstance(x, unicode) and str(x) or re.escape(x) for x in [ # math operators '+', '-', '*', '/', '%', @@ -32,7 +32,7 @@ operator_re = re.compile('(%s)' % '|'.join( # attribute access and comparison / logical operators '.', ':', ',', '|', '==', '<', '>', '<=', '>=', '!=', '=', ur'or\b', ur'and\b', ur'not\b', ur'in\b', ur'is' -])) +]])) # set of used keywords keywords = set(['and', 'block', 'cycle', 'elif', 'else', 'endblock', -- 2.26.2