From 8a48732f224717aaa56f5531170328d9130aff98 Mon Sep 17 00:00:00 2001
From: pw <pw>
Date: Tue, 2 Feb 1999 12:18:37 +0000
Subject: [PATCH] FILE-NAMESTRING now returns NIL instead of "" when applied to
 a directory pathname designator. This change may break some user code.

---
 code/filesys.lisp                | 4 ++--
 compiler/fndb.lisp               | 4 ++--
 contrib/defsystem/defsystem.lisp | 2 +-
 3 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/code/filesys.lisp b/code/filesys.lisp
index 879f9b2de..4569188fc 100644
--- a/code/filesys.lisp
+++ b/code/filesys.lisp
@@ -6,7 +6,7 @@
 ;;; Scott Fahlman or slisp-group@cs.cmu.edu.
 ;;;
 (ext:file-comment
-  "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/code/filesys.lisp,v 1.54 1998/12/19 16:03:58 dtc Exp $")
+  "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/code/filesys.lisp,v 1.55 1999/02/02 12:18:34 pw Exp $")
 ;;;
 ;;; **********************************************************************
 ;;;
@@ -412,7 +412,7 @@
 	(strings (if (eq version :wild)
 		     ".*"
 		     (format nil ".~D" version)))))
-    (apply #'concatenate 'simple-string (strings))))
+    (and (strings) (apply #'concatenate 'simple-string (strings)))))
 
 (defun unparse-unix-namestring (pathname)
   (declare (type pathname pathname))
diff --git a/compiler/fndb.lisp b/compiler/fndb.lisp
index 38b63fcfb..cc0a4cb3a 100644
--- a/compiler/fndb.lisp
+++ b/compiler/fndb.lisp
@@ -5,7 +5,7 @@
 ;;; Carnegie Mellon University, and has been placed in the public domain.
 ;;;
 (ext:file-comment
-  "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/fndb.lisp,v 1.84 1999/01/15 09:30:14 dtc Exp $")
+  "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/fndb.lisp,v 1.85 1999/02/02 12:18:36 pw Exp $")
 ;;;
 ;;; **********************************************************************
 ;;;
@@ -1005,7 +1005,7 @@
   pathname-version (flushable))
 
 (defknown (namestring file-namestring directory-namestring host-namestring)
-  (pathnamelike) simple-string
+  (pathnamelike) (or null simple-string)
   (flushable))
 
 (defknown enough-namestring (pathnamelike &optional pathnamelike)
diff --git a/contrib/defsystem/defsystem.lisp b/contrib/defsystem/defsystem.lisp
index b7d1804fb..991b778e0 100644
--- a/contrib/defsystem/defsystem.lisp
+++ b/contrib/defsystem/defsystem.lisp
@@ -1559,7 +1559,7 @@ s/^[^M]*IRIX Execution Environment 1, *[a-zA-Z]* *\\([^ ]*\\)/\\1/p\\
 	 (rel-directory (directory-to-list (pathname-directory rel-dir)))
 	 (rel-keyword (when (keywordp (car rel-directory))
 			(pop rel-directory)))
-	 (rel-file (file-namestring rel-dir))
+	 (rel-file (or (file-namestring rel-dir) ""))
 	 (directory nil))
     ;; TI Common Lisp pathnames can return garbage for file names because
     ;; of bizarreness in the merging of defaults.  The following code makes
-- 
GitLab