]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
bpo-35859: Fix a few long-standing bugs in re engine (GH-12427)
authorMa Lin <animalize@users.noreply.github.com>
Tue, 29 Mar 2022 14:31:01 +0000 (22:31 +0800)
committerGitHub <noreply@github.com>
Tue, 29 Mar 2022 14:31:01 +0000 (17:31 +0300)
commit356997cccc21a3391175d20e9ef03d434675b496
tree16392c0b0212d7680d04f0ccb85fa6e13d812a9a
parent788154919c2d843a0a995994bf2aed2d074761ec
bpo-35859: Fix a few long-standing bugs in re engine (GH-12427)

In rare cases, capturing group could get wrong result.

Regular expression engines in Perl and Java have similar bugs.
The new behavior now matches the behavior of more modern
RE engines: in the regex module and in PHP, Ruby and Node.js.
Doc/whatsnew/3.11.rst
Lib/test/test_re.py
Misc/NEWS.d/next/Library/2019-03-14-09-08-25.bpo-35859.8lFdLe.rst [new file with mode: 0644]
Modules/_sre.c
Modules/sre_lib.h