aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/Lib/codeop.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/codeop.py')
-rw-r--r--Lib/codeop.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/codeop.py b/Lib/codeop.py
index 547629262d0..4c10470aee7 100644
--- a/Lib/codeop.py
+++ b/Lib/codeop.py
@@ -85,9 +85,9 @@ def _maybe_compile(compiler, source, filename, symbol):
pass
# Catch syntax warnings after the first compile
- # to emit SyntaxWarning at most once.
+ # to emit warnings (SyntaxWarning, DeprecationWarning) at most once.
with warnings.catch_warnings():
- warnings.simplefilter("error", SyntaxWarning)
+ warnings.simplefilter("error")
try:
code1 = compiler(source + "\n", filename, symbol)