diff lisp/eshell/em-dirs.el @ 62915:b89e30bcd2bb

Changed all uses of `directory-sep-char' to ?/, and all uses of `string-to-int' to `string-to-number'.
author John Wiegley <johnw@newartisans.com>
date Tue, 31 May 2005 00:14:26 +0000
parents f243dc772a99
children 18a818a2ee7c 01137c1fdbe9
line wrap: on
line diff
--- a/lisp/eshell/em-dirs.el	Tue May 31 00:13:51 2005 +0000
+++ b/lisp/eshell/em-dirs.el	Tue May 31 00:14:26 2005 +0000
@@ -276,8 +276,7 @@
     (let* ((letter (match-string 1))
 	   (regexp (concat "\\`" letter))
 	   (path (eshell-find-previous-directory regexp)))
-      (concat (or path letter)
-	      (char-to-string directory-sep-char)))))
+      (concat (or path letter) "/"))))
 
 (defun eshell-complete-user-reference ()
   "If there is a user reference, complete it."
@@ -300,7 +299,7 @@
   (let* ((path default-directory)
 	 (len (length path)))
     (if (and (> len 1)
-	     (eq (aref path (1- len)) directory-sep-char)
+	     (eq (aref path (1- len)) ?/)
 	     (not (and (eshell-under-windows-p)
 		       (string-match "\\`[A-Za-z]:[\\\\/]\\'" path))))
 	(setq path (substring path 0 (1- (length path)))))
@@ -324,9 +323,7 @@
 	   (len (length extra-dots))
 	   replace-text)
       (while (> len 0)
-	(setq replace-text
-	      (concat replace-text
-		      (char-to-string directory-sep-char) "..")
+	(setq replace-text (concat replace-text "/..")
 	      len (1- len)))
       (setq path
 	    (replace-match replace-text t t path 1))))
@@ -371,7 +368,7 @@
 	(setq path
 	      (ring-remove eshell-last-dir-ring
 			   (if index
-			       (string-to-int index)
+			       (string-to-number index)
 			     0)))))
      ((and path (string-match "^=\\(.*\\)$" path))
       (let ((oldpath (eshell-find-previous-directory