summaryrefslogtreecommitdiffstats
path: root/Python/pylifecycle.c
diff options
context:
space:
mode:
authorBarney Gale <barney.gale@gmail.com>2023-05-31 20:37:37 (GMT)
committerGitHub <noreply@github.com>2023-05-31 20:37:37 (GMT)
commite7cb216339e8aa8d00f7f55f9e37864b1720ca0f (patch)
tree51cf3d735a04925c12f5d276c52153477345965c /Python/pylifecycle.c
parent076f3cda140a45b08c2c9518bc19624aae50d3a3 (diff)
downloadcpython-e7cb216339e8aa8d00f7f55f9e37864b1720ca0f.zip
cpython-e7cb216339e8aa8d00f7f55f9e37864b1720ca0f.tar.gz
cpython-e7cb216339e8aa8d00f7f55f9e37864b1720ca0f.tar.bz2
[3.12] GH-105113: Improve performance of `pathlib.PurePath.match()` (GH-105114)
We now compile a `re.Pattern` object for the entire pattern. This is made more difficult by `fnmatch` not treating directory separators as special when evaluating wildcards (`*`, `?`, etc), and so we arrange the path parts onto separate *lines* in a string, and ensure we don't set `re.DOTALL`. Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com> Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Diffstat (limited to 'Python/pylifecycle.c')
0 files changed, 0 insertions, 0 deletions