diff options
author | Stefan Monnier <monnier@iro.umontreal.ca> | 2010-11-23 12:36:15 -0500 |
---|---|---|
committer | Stefan Monnier <monnier@iro.umontreal.ca> | 2010-11-23 12:36:15 -0500 |
commit | 6e13206c036278d386b70e742355876b0340d28a (patch) | |
tree | 12563ed9a12eabe554db040d46e0fc1b4cd16395 /lisp/eshell/esh-arg.el | |
parent | 3d92f44ea0c9a356ce828b07db72c432f773b94c (diff) | |
download | emacs-6e13206c036278d386b70e742355876b0340d28a.tar.gz |
* lisp/eshell/: Use with-silent-modifications.
* lisp/eshell/esh-cmd.el (eshell-parse-command):
* lisp/eshell/esh-arg.el (eshell-parse-arguments):
* lisp/eshell/em-script.el (eshell-source-file):
Use with-silent-modifications.
Diffstat (limited to 'lisp/eshell/esh-arg.el')
-rw-r--r-- | lisp/eshell/esh-arg.el | 37 |
1 files changed, 18 insertions, 19 deletions
diff --git a/lisp/eshell/esh-arg.el b/lisp/eshell/esh-arg.el index 6395fe22d87..e6d73acd434 100644 --- a/lisp/eshell/esh-arg.el +++ b/lisp/eshell/esh-arg.el @@ -123,7 +123,7 @@ treated as a literal character." :type 'hook :group 'eshell-arg) -(defcustom eshell-delimiter-argument-list '(?\; ?& ?\| ?\> ? ?\t ?\n) +(defcustom eshell-delimiter-argument-list '(?\; ?& ?\| ?\> ?\s ?\t ?\n) "List of characters to recognize as argument separators." :type '(repeat character) :group 'eshell-arg) @@ -214,25 +214,24 @@ Point is left at the end of the arguments." (narrow-to-region beg end) (let ((inhibit-point-motion-hooks t) (args (list t)) - after-change-functions delim) - (remove-text-properties (point-min) (point-max) - '(arg-begin nil arg-end nil)) - (if (setq - delim - (catch 'eshell-incomplete - (while (not (eobp)) - (let* ((here (point)) - (arg (eshell-parse-argument))) - (if (= (point) here) - (error "Failed to parse argument '%s'" - (buffer-substring here (point-max)))) - (and arg (nconc args (list arg))))))) - (if (listp delim) - (throw 'eshell-incomplete delim) - (throw 'eshell-incomplete - (list delim (point) (cdr args))))) - (cdr args))))) + (with-silent-modifications + (remove-text-properties (point-min) (point-max) + '(arg-begin nil arg-end nil)) + (if (setq + delim + (catch 'eshell-incomplete + (while (not (eobp)) + (let* ((here (point)) + (arg (eshell-parse-argument))) + (if (= (point) here) + (error "Failed to parse argument '%s'" + (buffer-substring here (point-max)))) + (and arg (nconc args (list arg))))))) + (throw 'eshell-incomplete (if (listp delim) + delim + (list delim (point) (cdr args))))) + (cdr args)))))) (defun eshell-parse-argument () "Get the next argument. Leave point after it." |