asAbsolutePath

fnauto asAbsolutePath(R)(R path) if ((isRandomAccessRange!R && isSomeChar!(ElementType!R) || isNarrowString!R) && !isConvertibleToString!R)

Transforms path into an absolute path.

The following algorithm is used:

  1. If path is empty, return null.
  2. If path is already absolute, return it.
  3. Otherwise, append path to the current working directory,

    which allocates memory.

Note that asAbsolutePath will not normalize `..` segments. Use asNormalizedPath(asAbsolutePath(path)) if that is desired.

Parameters

paththe relative path to transform

Returns

the transformed path as a lazy range

See Also

absolutePath which returns an allocated string
fnauto asAbsolutePath(R)(auto ref R path) if (isConvertibleToString!R)
No documentation available for this declaration.