changeset 12202:0bd2831dff40

Test for "" too; let it go to expand-file-name if it is equal.
author Simon Marshall <simon@gnu.org>
date Tue, 13 Jun 1995 08:27:11 +0000
parents a302425220b9
children 0078571e5330
files lisp/files.el
diffstat 1 files changed, 5 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/files.el	Tue Jun 13 08:16:08 1995 +0000
+++ b/lisp/files.el	Tue Jun 13 08:27:11 1995 +0000
@@ -355,7 +355,11 @@
   ;; to chase before getting an error.
   ;; PREV-DIRS can be a cons cell whose car is an alist
   ;; of truenames we've just recently computed.
-  (if (or (string= filename "~")
+
+  ;; I don't understand the reason for these tests.  To avoid string-match?
+  ;; Something like (string-match "\\`\\'\\|~" filename) would do the same.
+  ;; The last test looks dubious, maybe `+' is meant here?  --simon.
+  (if (or (string= filename "") (string= filename "~")
 	  (and (string= (substring filename 0 1) "~")
 	       (string-match "~[^/]*" filename)))
       (progn