]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
gh-88569: add `ntpath.isreserved()` (#95486)
authorBarney Gale <barney.gale@gmail.com>
Fri, 26 Jan 2024 18:14:24 +0000 (18:14 +0000)
committerGitHub <noreply@github.com>
Fri, 26 Jan 2024 18:14:24 +0000 (18:14 +0000)
commit7e31d6dea276ac91402aefb023c58d239dfd9246
tree3a32adf17e7fa06baa399363f57a079d4f631f24
parent6c2b419fb91c8d7daa769d39f73768114b5eb45a
gh-88569: add `ntpath.isreserved()` (#95486)

Add `ntpath.isreserved()`, which identifies reserved pathnames such as "NUL", "AUX" and "CON".

Deprecate `pathlib.PurePath.is_reserved()`.

---------

Co-authored-by: Eryk Sun <eryksun@gmail.com>
Co-authored-by: Brett Cannon <brett@python.org>
Co-authored-by: Steve Dower <steve.dower@microsoft.com>
Doc/library/os.path.rst
Doc/library/pathlib.rst
Doc/whatsnew/3.13.rst
Lib/ntpath.py
Lib/pathlib/__init__.py
Lib/test/test_ntpath.py
Lib/test/test_pathlib/test_pathlib.py
Misc/NEWS.d/next/Library/2022-07-31-01-24-40.gh-issue-88569.eU0--b.rst [new file with mode: 0644]