pathname->string

Name

pathname->string -- Converts a pathname object to the corresponding string

Type: generic

Synopsis

pathname->string( pathname, string);

Arguments

pathname

A pathname object (an instance of <file-name> or <directory-name>)

Return Values

string

The string form of the pathname.

Description

This generic function is applied to a pathname to recover the string representation of the pathname. Directory names are returned with a trailing slash.

(define p (string->file "foo/bar/baz.scm"))

(pathname->string p) "foo/bar/baz.scm"

(pathname->string (file-directory p)) "foo/bar/"

The returned string does not expand any special root locations. See also pathname->os-path.