Skip to content

Commit

Permalink
Highlight python 3.10's EncodingWarning (#2106)
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinastock authored Apr 6, 2022
1 parent 06923a1 commit c155bc4
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pygments/lexers/python.py
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,8 @@ def fstring_rules(ttype):
'InterruptedError', 'IsADirectoryError', 'NotADirectoryError',
'PermissionError', 'ProcessLookupError', 'TimeoutError',
# others new in Python 3
'StopAsyncIteration', 'ModuleNotFoundError', 'RecursionError'),
'StopAsyncIteration', 'ModuleNotFoundError', 'RecursionError',
'EncodingWarning'),
prefix=r'(?<!\.)', suffix=r'\b'),
Name.Exception),
],
Expand Down

0 comments on commit c155bc4

Please sign in to comment.