changeset 5152:67b4642532bb

(comint-send-input): Don't call comint-arguments while computing the value for history. (comint-delim-arg): Treat quoted delim chars as non-delims.
author Richard M. Stallman <rms@gnu.org>
date Wed, 24 Nov 1993 05:12:36 +0000
parents 8b31cff02267
children 27afcc69725a
files lisp/comint.el
diffstat 1 files changed, 10 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/comint.el	Wed Nov 24 04:35:28 1993 +0000
+++ b/lisp/comint.el	Wed Nov 24 05:12:36 1993 +0000
@@ -983,9 +983,15 @@
   (if (or (null comint-delimiter-argument-list)
 	  (string-match "[\"\'\`]" arg))
       (list arg)
-    (let ((not-delim (format "[^%s]+" (mapconcat
-				       (function (lambda (d) (regexp-quote d)))
-				       comint-delimiter-argument-list "")))
+    (let ((not-delim (concat
+		      (format "\\([^%s]" (mapconcat
+					(function (lambda (d) (regexp-quote d)))
+					comint-delimiter-argument-list ""))
+		      "\\|"
+		      (mapconcat (function (lambda (d)
+					     (concat "\\\\" (regexp-quote d))))
+				 comint-delimiter-argument-list "\\|")
+		      "\\)+"))
 	  (delim-str (mapconcat (function (lambda (d)
 					    (concat (regexp-quote d) "+")))
 				comint-delimiter-argument-list "\\|"))
@@ -1080,10 +1086,7 @@
 			  ;; functions used do insertion, rather than return
 			  ;; strings.  We have to expand, then insert back.
 			  (comint-replace-by-expanded-history)
-			  (let ((copy (buffer-substring pmark (point))))
-			    (delete-region pmark (point))
-			    (insert input)
-			    (comint-arguments copy 0 nil)))))
+			  (buffer-substring pmark (point)))))
           (if comint-process-echoes
               (delete-region pmark (point))
 	    (insert ?\n))