summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormitsuhiko <devnull@localhost>2008-05-03 09:22:41 +0200
committermitsuhiko <devnull@localhost>2008-05-03 09:22:41 +0200
commite21198e0243d87ea5963d86700c94844216802ae (patch)
tree1ceb3561c11f9fe1273977ebf217fd933e9509b3
parentac88be9c45019d143d6333c60eb430fed66aa557 (diff)
downloadpygments-e21198e0243d87ea5963d86700c94844216802ae.tar.gz
django/jinja lexer supports jinja2's new pseudokeywords now
-rw-r--r--pygments/lexers/templates.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/pygments/lexers/templates.py b/pygments/lexers/templates.py
index 89fce87d..6921bdb2 100644
--- a/pygments/lexers/templates.py
+++ b/pygments/lexers/templates.py
@@ -237,7 +237,8 @@ class DjangoLexer(RegexLexer):
(r'(is)(\s+)(not)?(\s+)?([a-zA-Z_][a-zA-Z0-9_]*)',
bygroups(Keyword, Text, Keyword, Text, Name.Function)),
(r'(_|(?:true|false|undefined|null))\b', Keyword.Pseudo),
- (r'(in|as|reversed|recursive|not|and|or|with|is|if|else)\b', Keyword),
+ (r'(in|as|reversed|recursive|not|and|or|is|if|else|import|'
+ r'with(?:(?:out)?\s*context)?)\b', Keyword),
(r'(loop|block|forloop)\b', Name.Builtin),
(r'[a-zA-Z][a-zA-Z0-9_]*', Name.Variable),
(r'\.[a-zA-Z0-9_]+', Name.Variable),