diff options
author | Barney Gale <barney.gale@gmail.com> | 2023-04-09 17:40:03 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-04-09 17:40:03 (GMT) |
commit | 2c673d5e93cfe2779f27c4e742d7e50f7a94f356 (patch) | |
tree | 7b5aa0de6865ad59854a78765f31edb3bda6875f /Misc/NEWS.d | |
parent | 0a675f4bb57d01a5e69f8f58ae934ad7ca501a8d (diff) | |
download | cpython-2c673d5e93cfe2779f27c4e742d7e50f7a94f356.zip cpython-2c673d5e93cfe2779f27c4e742d7e50f7a94f356.tar.gz cpython-2c673d5e93cfe2779f27c4e742d7e50f7a94f356.tar.bz2 |
GH-101362: Omit path anchor from `pathlib.PurePath()._parts` (GH-102476)
Improve performance of path construction by skipping the addition of the path anchor (`drive + root`) to the internal `_parts` list. Rename this attribute to `_tail` for clarity.
Diffstat (limited to 'Misc/NEWS.d')
-rw-r--r-- | Misc/NEWS.d/next/Library/2023-03-06-18-49-57.gh-issue-101362.eSSy6L.rst | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Misc/NEWS.d/next/Library/2023-03-06-18-49-57.gh-issue-101362.eSSy6L.rst b/Misc/NEWS.d/next/Library/2023-03-06-18-49-57.gh-issue-101362.eSSy6L.rst new file mode 100644 index 0000000..87617a5 --- /dev/null +++ b/Misc/NEWS.d/next/Library/2023-03-06-18-49-57.gh-issue-101362.eSSy6L.rst @@ -0,0 +1,2 @@ +Speed up :class:`pathlib.Path` construction by omitting the path anchor from +the internal list of path parts. |