summaryrefslogtreecommitdiff
path: root/lisp/icomplete.el
diff options
context:
space:
mode:
authorRichard M. Stallman <rms@gnu.org>1994-08-03 21:23:30 +0000
committerRichard M. Stallman <rms@gnu.org>1994-08-03 21:23:30 +0000
commit0e551775a09bdfbcd9a14ba94063ea1e5f398d49 (patch)
tree10acbd0e1a57e238a2a78d9715010855343d60ce /lisp/icomplete.el
parentc57ca86e2aae77cc16a58da7ab35dd4c93dab1c7 (diff)
downloademacs-0e551775a09bdfbcd9a14ba94063ea1e5f398d49.tar.gz
(icomplete-prime-minibuffer): Copy the hook lists after making them local.
Diffstat (limited to 'lisp/icomplete.el')
-rw-r--r--lisp/icomplete.el8
1 files changed, 5 insertions, 3 deletions
diff --git a/lisp/icomplete.el b/lisp/icomplete.el
index a58229588b2..7defbb76a6d 100644
--- a/lisp/icomplete.el
+++ b/lisp/icomplete.el
@@ -75,23 +75,25 @@ non-nil. Set the var back to nil to re-enable icomplete."
'icomplete-post-command-hook 'append))
((format "icomplete: non v19 emacs, %s - %s"
emacs-version "try elisp-archive icomplete")))))
+
;;;_ > icomplete-prime-minibuffer ()
(defun icomplete-prime-minibuffer ()
-
"Prep emacs, v 19.18 or later, for icomplete.
-
\(In emacs v19.17 and earlier, and in lemacs, icomplete-prime-session
is used, instead to establish global hooks.\)
-Run via minibuffer-setup-hook, adds icomplete pre- and post-command
+Run via `minibuffer-setup-hook', adds icomplete pre- and post-command
hooks at the start of each minibuffer."
;; Append the hooks to avoid as much as posssible interference from
;; other hooks that foul up minibuffer quit.
(make-local-variable 'pre-command-hook)
(make-local-variable 'post-command-hook)
+ (setq pre-command-hook (copy-sequence pre-command-hook))
+ (setq post-command-hook (copy-sequence post-command-hook))
(add-hook 'pre-command-hook 'icomplete-pre-command-hook)
(add-hook 'post-command-hook 'icomplete-post-command-hook))
+
;;;_ > icomplete-window-minibuffer-p ()
(defmacro icomplete-window-minibuffer-p ()