summaryrefslogtreecommitdiffstats
path: root/Misc
diff options
context:
space:
mode:
authoranimalize <animalize@users.noreply.github.com>2019-02-18 13:26:37 (GMT)
committerSerhiy Storchaka <storchaka@gmail.com>2019-02-18 13:26:37 (GMT)
commit4a7f44a2ed49ff1e87db062e7177a56c6e4bbdb0 (patch)
tree6daa91592d1d09f5b8ed34a1121e600a8bb03d74 /Misc
parent02c04f26dfa637db7091b7e16036a980bbf40893 (diff)
downloadcpython-4a7f44a2ed49ff1e87db062e7177a56c6e4bbdb0.zip
cpython-4a7f44a2ed49ff1e87db062e7177a56c6e4bbdb0.tar.gz
cpython-4a7f44a2ed49ff1e87db062e7177a56c6e4bbdb0.tar.bz2
bpo-34294: re module, fix wrong capturing groups in rare cases. (GH-11546)
Need to reset capturing groups between two SRE(match) callings in loops, this fixes wrong capturing groups in rare cases. Also add a missing index in re.rst.
Diffstat (limited to 'Misc')
-rw-r--r--Misc/NEWS.d/next/Library/2019-01-14-11-53-10.bpo-34294.3JFdg2.rst4
1 files changed, 4 insertions, 0 deletions
diff --git a/Misc/NEWS.d/next/Library/2019-01-14-11-53-10.bpo-34294.3JFdg2.rst b/Misc/NEWS.d/next/Library/2019-01-14-11-53-10.bpo-34294.3JFdg2.rst
new file mode 100644
index 0000000..e1ae2ea
--- /dev/null
+++ b/Misc/NEWS.d/next/Library/2019-01-14-11-53-10.bpo-34294.3JFdg2.rst
@@ -0,0 +1,4 @@
+re module, fix wrong capturing groups in rare cases. :func:`re.search`,
+:func:`re.findall`, :func:`re.sub` and other functions that scan through
+string looking for a match, should reset capturing groups between two match
+attempts. Patch by Ma Lin. \ No newline at end of file