![](https://secure.gravatar.com/avatar/283647207f2c41c9f8a1c1a7a1ec5b25.jpg?s=120&d=mm&r=g)
10 Jul
2009
10 Jul
'09
5:44 p.m.
I believe that FILE-NAMESTRING is supposed to do roughly what you want here.
excellent!
(defun ensure-directory-pathname (pathname) (if (directory-pathname-p pathname) pathname (make-pathname :directory `(,@(pathname-directory pathname) ,(namestring (pathname-name+type pathname))))))
This loses the device component from PATHNAME, and is otherwise prone to fail in case the host component of *DEFAULT-PATHNAME-DEFAULTS* differs from the host component of PATHNAME. How about
absolutely. -- Gary Warren King, metabang.com Cell: (413) 559 8738 Fax: (206) 338-4052 gwkkwg on Skype * garethsan on AIM * gwking on twitter