summaryrefslogtreecommitdiffstats
path: root/Lib/idlelib/searchengine.py
diff options
context:
space:
mode:
authorachhina <amanschhina@gmail.com>2023-12-11 20:45:08 (GMT)
committerGitHub <noreply@github.com>2023-12-11 20:45:08 (GMT)
commita01022af23b27a9bfb4fadbcdb60b1ddf24a7220 (patch)
tree94379f595ca9d2b19effd282e2f8fc10ead2ae72 /Lib/idlelib/searchengine.py
parent0066ab5bc58a036b3f448cd6f9bbdd92120e39ba (diff)
downloadcpython-a01022af23b27a9bfb4fadbcdb60b1ddf24a7220.zip
cpython-a01022af23b27a9bfb4fadbcdb60b1ddf24a7220.tar.gz
cpython-a01022af23b27a9bfb4fadbcdb60b1ddf24a7220.tar.bz2
GH-83162: Rename re.error for better clarity. (#101677)
Renamed re.error for clarity, and kept re.error for backward compatibility. Updated idlelib files at TJR's request. --------- Co-authored-by: Matthias Bussonnier <mbussonnier@ucmerced.edu> Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com> Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
Diffstat (limited to 'Lib/idlelib/searchengine.py')
-rw-r--r--Lib/idlelib/searchengine.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/idlelib/searchengine.py b/Lib/idlelib/searchengine.py
index 0684142..ceb38cf 100644
--- a/Lib/idlelib/searchengine.py
+++ b/Lib/idlelib/searchengine.py
@@ -84,7 +84,7 @@ class SearchEngine:
flags = flags | re.IGNORECASE
try:
prog = re.compile(pat, flags)
- except re.error as e:
+ except re.PatternError as e:
self.report_error(pat, e.msg, e.pos)
return None
return prog