Skip to content
Snippets Groups Projects
Commit 6d47b84c authored by Robert P. Goldman's avatar Robert P. Goldman
Browse files

More work on DIRECTORY-FILES.

Use clisp-specific function in DIRECTORY-EXISTS-P implementation.
Use lower-cost DIRECTORY-PATHNAME-P instead of DIRECTORY-EXISTS-P in
DIRECTORY-FILES.
parent c2baa6fa
No related branches found
No related tags found
No related merge requests found
...@@ -144,7 +144,11 @@ or the original (parsed) pathname if it is false (the default)." ...@@ -144,7 +144,11 @@ or the original (parsed) pathname if it is false (the default)."
"Is X the name of a directory that exists on the filesystem?" "Is X the name of a directory that exists on the filesystem?"
#+allegro #+allegro
(excl:probe-directory x) (excl:probe-directory x)
#-allegro #+clisp
(handler-case (ext:probe-directory x)
(sys::simple-file-error ()
nil))
#-(or allegro clisp)
(let ((p (probe-file* x :truename t))) (let ((p (probe-file* x :truename t)))
(and (directory-pathname-p p) p))) (and (directory-pathname-p p) p)))
...@@ -211,7 +215,7 @@ permits this." ...@@ -211,7 +215,7 @@ permits this."
#+clisp #+clisp
(when (equal :wild (pathname-type pattern)) (when (equal :wild (pathname-type pattern))
(ignore-errors (directory* (make-pathname :type nil :defaults pat))))))) (ignore-errors (directory* (make-pathname :type nil :defaults pat)))))))
(remove-if 'directory-exists-p (remove-if 'directory-pathname-p
(filter-logical-directory-results (filter-logical-directory-results
directory entries directory entries
#'(lambda (f) #'(lambda (f)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment