diff options
author | Tim Hatch <tim@timhatch.com> | 2014-05-16 14:20:32 -0700 |
---|---|---|
committer | Tim Hatch <tim@timhatch.com> | 2014-05-16 14:20:32 -0700 |
commit | 6c1b71840afd3abc6577452ed47c813290245491 (patch) | |
tree | d581a50109fca8122e92ed6dcfb63b5834462b07 /pygments/lexers/parsers.py | |
parent | d961cec379aa5bba2102af3627002968aa2d0173 (diff) | |
parent | 45c6a7514c20a476ac20d5dd6979524b3c5232ea (diff) | |
download | pygments-6c1b71840afd3abc6577452ed47c813290245491.tar.gz |
Merged in jaingaurav2/pygments-main (pull request #357)
Numerous regexlint fixes
Diffstat (limited to 'pygments/lexers/parsers.py')
-rw-r--r-- | pygments/lexers/parsers.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/pygments/lexers/parsers.py b/pygments/lexers/parsers.py index fc8cbb6f..4c23c760 100644 --- a/pygments/lexers/parsers.py +++ b/pygments/lexers/parsers.py @@ -102,7 +102,7 @@ class RagelLexer(RegexLexer): 'host': [ (r'(' + r'|'.join(( # keep host code in largest possible chunks r'[^{}\'"/#]+', # exclude unsafe characters - r'[^\\][\\][{}]', # allow escaped { or } + r'[^\\]\\[{}]', # allow escaped { or } # strings and comments may safely contain unsafe characters r'"(\\\\|\\"|[^"])*"', # double quote string @@ -173,7 +173,7 @@ class RagelEmbeddedLexer(RegexLexer): r'[^}\'"\[/#]', # exclude unsafe characters r'}(?=[^%]|$)', # } is okay as long as it's not followed by % r'}%(?=[^%]|$)', # ...well, one %'s okay, just not two... - r'[^\\][\\][{}]', # ...and } is okay if it's escaped + r'[^\\]\\[{}]', # ...and } is okay if it's escaped # allow / if it's preceded with one of these symbols # (ragel EOF actions) |