summaryrefslogtreecommitdiff
path: root/pygments/lexers/python.py
diff options
context:
space:
mode:
Diffstat (limited to 'pygments/lexers/python.py')
-rw-r--r--pygments/lexers/python.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/pygments/lexers/python.py b/pygments/lexers/python.py
index 8e1debac..993a9359 100644
--- a/pygments/lexers/python.py
+++ b/pygments/lexers/python.py
@@ -176,7 +176,7 @@ class PythonLexer(RegexLexer):
'InterruptedError', 'IsADirectoryError', 'NotADirectoryError',
'PermissionError', 'ProcessLookupError', 'TimeoutError',
# others new in Python 3
- 'StopAsyncIteration'),
+ 'StopAsyncIteration', 'ModuleNotFoundError', 'RecursionError'),
prefix=r'(?<!\.)', suffix=r'\b'),
Name.Exception),
],
@@ -391,9 +391,9 @@ class Python2Lexer(RegexLexer):
'Exception', 'FloatingPointError', 'FutureWarning', 'GeneratorExit',
'IOError', 'ImportError', 'ImportWarning', 'IndentationError',
'IndexError', 'KeyError', 'KeyboardInterrupt', 'LookupError',
- 'MemoryError', 'ModuleNotFoundError', 'NameError',
+ 'MemoryError', 'NameError',
'NotImplementedError', 'OSError', 'OverflowError', 'OverflowWarning',
- 'PendingDeprecationWarning', 'RecursionError', 'ReferenceError',
+ 'PendingDeprecationWarning', 'ReferenceError',
'RuntimeError', 'RuntimeWarning', 'StandardError', 'StopIteration',
'SyntaxError', 'SyntaxWarning', 'SystemError', 'SystemExit',
'TabError', 'TypeError', 'UnboundLocalError', 'UnicodeDecodeError',