summaryrefslogtreecommitdiff
path: root/lisp/eshell
diff options
context:
space:
mode:
Diffstat (limited to 'lisp/eshell')
-rw-r--r--lisp/eshell/esh-arg.el5
1 files changed, 4 insertions, 1 deletions
diff --git a/lisp/eshell/esh-arg.el b/lisp/eshell/esh-arg.el
index 77db1bfc100..0b68bd69a0a 100644
--- a/lisp/eshell/esh-arg.el
+++ b/lisp/eshell/esh-arg.el
@@ -52,7 +52,10 @@ yield the values intended."
(looking-at eshell-number-regexp)
(eshell-arg-delimiter (match-end 0)))
(goto-char (match-end 0))
- (string-to-number (match-string 0)))))
+ (let ((str (match-string 0)))
+ (if (> (length str) 0)
+ (add-text-properties 0 1 '(number t) str))
+ str))))
;; parse any non-special characters, based on the current context
(function