Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Added pathname-samep

darcs-hash:20080621010440-3cc5d-51d96b476d98482a2e7e7169a84bc44607b304ab.gz
  • Loading branch information...
commit dab04ac136f6da5e94cdca1ce14ed9613e2d9087 1 parent 68a1eba
@gwkkwg authored
Showing with 10 additions and 0 deletions.
  1. +9 −0 dev/l0-files.lisp
  2. +1 −0  dev/package.lisp
View
9 dev/l0-files.lisp
@@ -73,6 +73,15 @@
:directory `(,@(pathname-directory pathname)
,(namestring (pathname-name+type pathname))))))
+(defun pathname-samep (p1 p2)
+ "Returns true if the logical translations of `p1` and `p2` have
+the same (`string=`) namestrings."
+ (and p1 p2
+ (typep p1 '(or string pathname))
+ (typep p2 '(or string pathname))
+ (string= (namestring (translate-logical-pathname p1))
+ (namestring (translate-logical-pathname p2)))))
+
(defgeneric make-stream-from-specifier (specifier direction &rest args)
(:documentation "Create and return a stream from specifier, direction and any other argsuments"))
View
1  dev/package.lisp
@@ -320,6 +320,7 @@
(:export
#:invalid-stream-specifier-error
+ #:pathname-samep
#:file-to-list
#:file-newer-than-file-p
#:conjure-up-filename
Please sign in to comment.
Something went wrong with that request. Please try again.