summaryrefslogtreecommitdiff
path: root/lisp/eshell/esh-util.el
diff options
context:
space:
mode:
authorJohn Wiegley <johnw@newartisans.com>2005-05-31 00:14:26 +0000
committerJohn Wiegley <johnw@newartisans.com>2005-05-31 00:14:26 +0000
commit6b0e3e4df5deff8b5d1dcb5065c070abb8393e9d (patch)
treec20c50525936f9970338856e57bac951c4b3696e /lisp/eshell/esh-util.el
parentc7a4ce37e95f0ac17d80bdb7c2b1280b82b186fb (diff)
downloademacs-6b0e3e4df5deff8b5d1dcb5065c070abb8393e9d.tar.gz
Changed all uses of `directory-sep-char' to ?/, and all uses of
`string-to-int' to `string-to-number'.
Diffstat (limited to 'lisp/eshell/esh-util.el')
-rw-r--r--lisp/eshell/esh-util.el17
1 files changed, 7 insertions, 10 deletions
diff --git a/lisp/eshell/esh-util.el b/lisp/eshell/esh-util.el
index a2fd0915cf4..91317300ca5 100644
--- a/lisp/eshell/esh-util.el
+++ b/lisp/eshell/esh-util.el
@@ -253,14 +253,13 @@ If N or M is nil, it means the end of the list."
parts)
(if (and (eshell-under-windows-p)
(> len 2)
- (eq (aref path 0) directory-sep-char)
- (eq (aref path 1) directory-sep-char))
+ (eq (aref path 0) ?/)
+ (eq (aref path 1) ?/))
(setq i 2))
(while (< i len)
- (if (and (eq (aref path i) directory-sep-char)
+ (if (and (eq (aref path i) ?/)
(not (get-text-property i 'escaped path)))
- (setq parts (cons (if (= li i)
- (char-to-string directory-sep-char)
+ (setq parts (cons (if (= li i) "/"
(substring path li (1+ i))) parts)
li (1+ i)))
(setq i (1+ i)))
@@ -268,9 +267,7 @@ If N or M is nil, it means the end of the list."
(setq parts (cons (substring path li i) parts)))
(if (and (eshell-under-windows-p)
(string-match "\\`[A-Za-z]:\\'" (car (last parts))))
- (setcar (last parts)
- (concat (car (last parts))
- (char-to-string directory-sep-char))))
+ (setcar (last parts) (concat (car (last parts)) "/")))
(nreverse parts)))
(defun eshell-to-flat-string (value)
@@ -450,8 +447,8 @@ list."
(point) (progn (end-of-line)
(point))) ":")))
(if (and (and fields (nth 0 fields) (nth 2 fields))
- (not (assq (string-to-int (nth 2 fields)) names)))
- (setq names (cons (cons (string-to-int (nth 2 fields))
+ (not (assq (string-to-number (nth 2 fields)) names)))
+ (setq names (cons (cons (string-to-number (nth 2 fields))
(nth 0 fields))
names))))
(forward-line))))