diff options
author | robot-contrib <[email protected]> | 2024-07-02 22:47:57 +0300 |
---|---|---|
committer | robot-contrib <[email protected]> | 2024-07-02 22:59:47 +0300 |
commit | 96b239778766d32d5158aca805e08199b3c0a743 (patch) | |
tree | a9c8679261a62138ec4735d878a11f6478cd196a /contrib/tools/python3/Lib/ntpath.py | |
parent | 292e7317266c2136a1e1bd027e16e6eefb639028 (diff) |
Update contrib/tools/python3 to 3.12.4
6e8edffbef193b35b45ddccdc3beda6bb2627186
Diffstat (limited to 'contrib/tools/python3/Lib/ntpath.py')
-rw-r--r-- | contrib/tools/python3/Lib/ntpath.py | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/contrib/tools/python3/Lib/ntpath.py b/contrib/tools/python3/Lib/ntpath.py index df3402d46c9..2e290dcf9de 100644 --- a/contrib/tools/python3/Lib/ntpath.py +++ b/contrib/tools/python3/Lib/ntpath.py @@ -521,7 +521,7 @@ def expandvars(path): # Previously, this function also truncated pathnames to 8+3 format, # but as this module is called "ntpath", that's obviously wrong! try: - from nt import _path_normpath + from nt import _path_normpath as normpath except ImportError: def normpath(path): @@ -560,14 +560,6 @@ except ImportError: comps.append(curdir) return prefix + sep.join(comps) -else: - def normpath(path): - """Normalize path, eliminating double slashes, etc.""" - path = os.fspath(path) - if isinstance(path, bytes): - return os.fsencode(_path_normpath(os.fsdecode(path))) or b"." - return _path_normpath(path) or "." - def _abspath_fallback(path): """Return the absolute version of a path as a fallback function in case |