diff options
| author | Glenn Morris | 2010-11-06 12:44:11 -0700 |
|---|---|---|
| committer | Glenn Morris | 2010-11-06 12:44:11 -0700 |
| commit | 8f6c3eace0813df73c68c77ef63bdb2a4ba55341 (patch) | |
| tree | d124d0ca7057ced3fd94a0ec6520ae1cbe319cb3 | |
| parent | 79d1dabe009ea0d18c47a39ca3c8a582f7bbea8b (diff) | |
| download | emacs-8f6c3eace0813df73c68c77ef63bdb2a4ba55341.tar.gz emacs-8f6c3eace0813df73c68c77ef63bdb2a4ba55341.zip | |
Silence viper-cmd compilation.
* lisp/emulation/viper-cmd.el (viper-read-string-with-history):
Prefix dynamic local `initial'.
(viper-minibuffer-standard-hook): Update for above name change.
| -rw-r--r-- | lisp/ChangeLog | 4 | ||||
| -rw-r--r-- | lisp/emulation/viper-cmd.el | 38 |
2 files changed, 22 insertions, 20 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 882f2235435..5bf9f565ca0 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,5 +1,9 @@ | |||
| 1 | 2010-11-06 Glenn Morris <rgm@gnu.org> | 1 | 2010-11-06 Glenn Morris <rgm@gnu.org> |
| 2 | 2 | ||
| 3 | * emulation/viper-cmd.el (viper-read-string-with-history): | ||
| 4 | Prefix dynamic local `initial'. | ||
| 5 | (viper-minibuffer-standard-hook): Update for above name change. | ||
| 6 | |||
| 3 | * emacs-lisp/elint.el (elint-init-env): Prefix dynamic local `env'. | 7 | * emacs-lisp/elint.el (elint-init-env): Prefix dynamic local `env'. |
| 4 | (elint-init-form): Update for above name change. | 8 | (elint-init-form): Update for above name change. |
| 5 | 9 | ||
diff --git a/lisp/emulation/viper-cmd.el b/lisp/emulation/viper-cmd.el index 07719ba45be..25c3934485c 100644 --- a/lisp/emulation/viper-cmd.el +++ b/lisp/emulation/viper-cmd.el | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | ;;; viper-cmd.el --- Vi command support for Viper | 1 | ;;; viper-cmd.el --- Vi command support for Viper |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, | 3 | ;; Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, |
| 4 | ;; 2005, 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc. | 4 | ;; 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc. |
| 5 | 5 | ||
| 6 | ;; Author: Michael Kifer <kifer@cs.stonybrook.edu> | 6 | ;; Author: Michael Kifer <kifer@cs.stonybrook.edu> |
| 7 | ;; Package: viper | 7 | ;; Package: viper |
| @@ -42,7 +42,7 @@ | |||
| 42 | (defvar quail-current-str) | 42 | (defvar quail-current-str) |
| 43 | (defvar mark-even-if-inactive) | 43 | (defvar mark-even-if-inactive) |
| 44 | (defvar init-message) | 44 | (defvar init-message) |
| 45 | (defvar initial) | 45 | (defvar viper-initial) |
| 46 | (defvar undo-beg-posn) | 46 | (defvar undo-beg-posn) |
| 47 | (defvar undo-end-posn) | 47 | (defvar undo-end-posn) |
| 48 | 48 | ||
| @@ -2065,23 +2065,22 @@ Undo previous insertion and inserts new." | |||
| 2065 | (funcall hook) | 2065 | (funcall hook) |
| 2066 | )) | 2066 | )) |
| 2067 | 2067 | ||
| 2068 | ;; Thie is a temp hook that uses free variables init-message and initial. | 2068 | ;; This is a temp hook that uses free variables init-message and viper-initial. |
| 2069 | ;; A dirty feature, but it is the simplest way to have it do the right thing. | 2069 | ;; A dirty feature, but it is the simplest way to have it do the right thing. |
| 2070 | ;; The INIT-MESSAGE and INITIAL vars come from the scope set by | 2070 | ;; The INIT-MESSAGE and VIPER-INITIAL vars come from the scope set by |
| 2071 | ;; viper-read-string-with-history | 2071 | ;; viper-read-string-with-history |
| 2072 | (defun viper-minibuffer-standard-hook () | 2072 | (defun viper-minibuffer-standard-hook () |
| 2073 | (if (stringp init-message) | 2073 | (if (stringp init-message) |
| 2074 | (viper-tmp-insert-at-eob init-message)) | 2074 | (viper-tmp-insert-at-eob init-message)) |
| 2075 | (if (stringp initial) | 2075 | (when (stringp viper-initial) |
| 2076 | (progn | 2076 | ;; don't wait if we have unread events or in kbd macro |
| 2077 | ;; don't wait if we have unread events or in kbd macro | 2077 | (or unread-command-events |
| 2078 | (or unread-command-events | 2078 | executing-kbd-macro |
| 2079 | executing-kbd-macro | 2079 | (sit-for 840)) |
| 2080 | (sit-for 840)) | 2080 | (if (fboundp 'minibuffer-prompt-end) |
| 2081 | (if (fboundp 'minibuffer-prompt-end) | 2081 | (delete-region (minibuffer-prompt-end) (point-max)) |
| 2082 | (delete-region (minibuffer-prompt-end) (point-max)) | 2082 | (erase-buffer)) |
| 2083 | (erase-buffer)) | 2083 | (insert viper-initial))) |
| 2084 | (insert initial)))) | ||
| 2085 | 2084 | ||
| 2086 | (defsubst viper-minibuffer-real-start () | 2085 | (defsubst viper-minibuffer-real-start () |
| 2087 | (if (fboundp 'minibuffer-prompt-end) | 2086 | (if (fboundp 'minibuffer-prompt-end) |
| @@ -2180,10 +2179,10 @@ problems." | |||
| 2180 | 2179 | ||
| 2181 | ;;; Reading string with history | 2180 | ;;; Reading string with history |
| 2182 | 2181 | ||
| 2183 | (defun viper-read-string-with-history (prompt &optional initial | 2182 | (defun viper-read-string-with-history (prompt &optional viper-initial |
| 2184 | history-var default keymap | 2183 | history-var default keymap |
| 2185 | init-message) | 2184 | init-message) |
| 2186 | ;; Read string, prompting with PROMPT and inserting the INITIAL | 2185 | ;; Read string, prompting with PROMPT and inserting the VIPER-INITIAL |
| 2187 | ;; value. Uses HISTORY-VAR. DEFAULT is the default value to accept if the | 2186 | ;; value. Uses HISTORY-VAR. DEFAULT is the default value to accept if the |
| 2188 | ;; input is an empty string. | 2187 | ;; input is an empty string. |
| 2189 | ;; Default value is displayed until the user types something in the | 2188 | ;; Default value is displayed until the user types something in the |
| @@ -2206,14 +2205,14 @@ problems." | |||
| 2206 | temp-msg) | 2205 | temp-msg) |
| 2207 | 2206 | ||
| 2208 | (setq keymap (or keymap minibuffer-local-map) | 2207 | (setq keymap (or keymap minibuffer-local-map) |
| 2209 | initial (or initial "") | 2208 | viper-initial (or viper-initial "") |
| 2210 | temp-msg (if default | 2209 | temp-msg (if default |
| 2211 | (format "(default %s) " default) | 2210 | (format "(default %s) " default) |
| 2212 | "")) | 2211 | "")) |
| 2213 | 2212 | ||
| 2214 | (setq viper-incomplete-ex-cmd nil) | 2213 | (setq viper-incomplete-ex-cmd nil) |
| 2215 | (setq val (read-from-minibuffer prompt | 2214 | (setq val (read-from-minibuffer prompt |
| 2216 | (concat temp-msg initial val padding) | 2215 | (concat temp-msg viper-initial val padding) |
| 2217 | keymap nil history-var)) | 2216 | keymap nil history-var)) |
| 2218 | (setq minibuffer-setup-hook nil | 2217 | (setq minibuffer-setup-hook nil |
| 2219 | padding (viper-array-to-string (this-command-keys)) | 2218 | padding (viper-array-to-string (this-command-keys)) |
| @@ -5093,5 +5092,4 @@ Mail anyway (y or n)? ") | |||
| 5093 | 5092 | ||
| 5094 | 5093 | ||
| 5095 | 5094 | ||
| 5096 | ;; arch-tag: 739a6450-5fda-44d0-88b0-325053d888c2 | ||
| 5097 | ;;; viper-cmd.el ends here | 5095 | ;;; viper-cmd.el ends here |