summaryrefslogtreecommitdiffstats
path: root/Lib/pathlib.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/pathlib.py')
-rw-r--r--Lib/pathlib.py11
1 files changed, 3 insertions, 8 deletions
diff --git a/Lib/pathlib.py b/Lib/pathlib.py
index d42ee4d..1603325 100644
--- a/Lib/pathlib.py
+++ b/Lib/pathlib.py
@@ -1043,24 +1043,19 @@ class Path(PurePath):
yield p
def absolute(self):
- """Return an absolute version of this path. This function works
- even if the path doesn't point to anything.
+ """Return an absolute version of this path by prepending the current
+ working directory. No normalization or symlink resolution is performed.
- No normalization is done, i.e. all '.' and '..' will be kept along.
Use resolve() to get the canonical path to a file.
"""
- # XXX untested yet!
if self.is_absolute():
return self
- # FIXME this must defer to the specific flavour (and, under Windows,
- # use nt._getfullpathname())
return self._from_parts([self._accessor.getcwd()] + self._parts)
def resolve(self, strict=False):
"""
Make the path absolute, resolving all symlinks on the way and also
- normalizing it (for example turning slashes into backslashes under
- Windows).
+ normalizing it.
"""
def check_eloop(e):