Function: eshell-convert
eshell-convert is a byte-compiled function defined in esh-util.el.gz.
Signature
(eshell-convert STRING)
Documentation
Convert STRING into a more native looking Lisp object.
Source Code
;; Defined in /usr/src/emacs/lisp/eshell/esh-util.el.gz
(defun eshell-convert (string)
"Convert STRING into a more native looking Lisp object."
(if (not (stringp string))
string
(let ((len (length string)))
(if (= len 0)
string
(if (eq (aref string (1- len)) ?\n)
(setq string (substring string 0 (1- len))))
(if (string-search "\n" string)
(split-string string "\n")
(if (and eshell-convert-numeric-arguments
(string-match
(concat "\\`\\s-*" eshell-number-regexp
"\\s-*\\'") string))
(string-to-number string)
string))))))