diff options
author | Georg Brandl <georg@python.org> | 2020-09-06 11:55:52 +0200 |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2020-09-06 11:55:52 +0200 |
commit | 603e8eddbf413deeb452ff110431da001e795438 (patch) | |
tree | 16c142fbcdd30defd672694611747d7da2f2f656 /pygments/lexers/python.py | |
parent | 3a2752177f37188fe995d262beb94a338dca612a (diff) | |
download | pygments-git-603e8eddbf413deeb452ff110431da001e795438.tar.gz |
all: fixup remaining regexlint warnings
Diffstat (limited to 'pygments/lexers/python.py')
-rw-r--r-- | pygments/lexers/python.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/pygments/lexers/python.py b/pygments/lexers/python.py index 7540489c..ba037eb3 100644 --- a/pygments/lexers/python.py +++ b/pygments/lexers/python.py @@ -172,19 +172,19 @@ class PythonLexer(RegexLexer): # without format specifier (r'(=\s*)?' # debug (https://bugs.python.org/issue36817) r'(\![sraf])?' # conversion - r'}', String.Interpol, '#pop'), + r'\}', String.Interpol, '#pop'), # with format specifier # we'll catch the remaining '}' in the outer scope (r'(=\s*)?' # debug (https://bugs.python.org/issue36817) r'(\![sraf])?' # conversion r':', String.Interpol, '#pop'), - (r'[^\S]+', Text), # allow new lines + (r'\s+', Text), # allow new lines include('expr'), ], 'expr-inside-fstring-inner': [ (r'[{([]', Punctuation, 'expr-inside-fstring-inner'), (r'[])}]', Punctuation, '#pop'), - (r'[^\S]+', Text), # allow new lines + (r'\s+', Text), # allow new lines include('expr'), ], 'expr-keywords': [ @@ -317,8 +317,8 @@ class PythonLexer(RegexLexer): default('#pop'), ], 'fstringescape': [ - ('{{', String.Escape), - ('}}', String.Escape), + (r'\{\{', String.Escape), + (r'\}\}', String.Escape), include('stringescape'), ], 'stringescape': [ |