Move define-obsolete-variable-alias before the var's definition.

* lisp/vc/log-edit.el (vc-comment-ring, vc-comment-ring-index):
* lisp/tooltip.el (tooltip-hook):
* lisp/textmodes/reftex-toc.el (reftex-toc-map):
* lisp/textmodes/reftex-sel.el (reftex-select-label-map)
(reftex-select-bib-map):
* lisp/textmodes/reftex-index.el (reftex-index-map)
(reftex-index-phrases-map):
* lisp/speedbar.el (speedbar-syntax-table, speedbar-key-map):
* lisp/progmodes/meta-mode.el (meta-mode-map):
* lisp/novice.el (disabled-command-hook):
* lisp/loadhist.el (unload-hook-features-list):
* lisp/frame.el (blink-cursor):
* lisp/files.el (find-file-not-found-hooks, write-file-hooks)
(write-contents-hooks):
* lisp/emulation/tpu-edt.el (GOLD-map):
* lisp/emacs-lock.el (emacs-lock-from-exiting):
* lisp/emacs-lisp/generic.el (generic-font-lock-defaults):
* lisp/emacs-lisp/chart.el (chart-map):
* lisp/dos-fns.el (register-name-alist):
* lisp/dired-x.el (dired-omit-files-p):
* lisp/desktop.el (desktop-enable):
* lisp/cus-edit.el (custom-mode-hook):
* lisp/buff-menu.el (buffer-menu-mode-hook):
* lisp/bookmark.el (bookmark-read-annotation-text-func)
(bookmark-exit-hooks):
* lisp/allout.el (allout-mode-deactivate-hook)
(allout-exposure-change-hook, allout-structure-added-hook)
(allout-structure-deleted-hook, allout-structure-shifted-hook):
* lisp/dirtrack.el (dirtrack-toggle, dirtrackp, dirtrack-debug-toggle)
(dirtrack-debug): Move call to define-obsolete-variable-alias so it
comes before the corresponding variable's definition.
This commit is contained in:
Stefan Monnier 2012-05-12 23:05:06 -04:00
parent 9e6b06ed73
commit e5bd0a2895
24 changed files with 103 additions and 75 deletions

View file

@ -1,3 +1,38 @@
2012-05-13 Stefan Monnier <monnier@iro.umontreal.ca>
Move define-obsolete-variable-alias before the var's definition.
* vc/log-edit.el (vc-comment-ring, vc-comment-ring-index):
* tooltip.el (tooltip-hook):
* textmodes/reftex-toc.el (reftex-toc-map):
* textmodes/reftex-sel.el (reftex-select-label-map)
(reftex-select-bib-map):
* textmodes/reftex-index.el (reftex-index-map)
(reftex-index-phrases-map):
* speedbar.el (speedbar-syntax-table, speedbar-key-map):
* progmodes/meta-mode.el (meta-mode-map):
* novice.el (disabled-command-hook):
* loadhist.el (unload-hook-features-list):
* frame.el (blink-cursor):
* files.el (find-file-not-found-hooks, write-file-hooks)
(write-contents-hooks):
* emulation/tpu-edt.el (GOLD-map):
* emacs-lock.el (emacs-lock-from-exiting):
* emacs-lisp/generic.el (generic-font-lock-defaults):
* emacs-lisp/chart.el (chart-map):
* dos-fns.el (register-name-alist):
* dired-x.el (dired-omit-files-p):
* desktop.el (desktop-enable):
* cus-edit.el (custom-mode-hook):
* buff-menu.el (buffer-menu-mode-hook):
* bookmark.el (bookmark-read-annotation-text-func)
(bookmark-exit-hooks):
* allout.el (allout-mode-deactivate-hook)
(allout-exposure-change-hook, allout-structure-added-hook)
(allout-structure-deleted-hook, allout-structure-shifted-hook):
* dirtrack.el (dirtrack-toggle, dirtrackp, dirtrack-debug-toggle)
(dirtrack-debug): Move call to define-obsolete-variable-alias so it
comes before the corresponding variable's definition.
2012-05-12 Chong Yidong <cyd@gnu.org> 2012-05-12 Chong Yidong <cyd@gnu.org>
* buff-menu.el (Buffer-menu-buffer+size-width): Doc fix (Bug#11454). * buff-menu.el (Buffer-menu-buffer+size-width): Doc fix (Bug#11454).

View file

@ -1405,15 +1405,17 @@ their settings before allout-mode was started."
(defvar allout-mode-hook nil (defvar allout-mode-hook nil
"Hook run when allout mode starts.") "Hook run when allout mode starts.")
;;;_ = allout-mode-deactivate-hook ;;;_ = allout-mode-deactivate-hook
(defvar allout-mode-deactivate-hook nil
"Hook run when allout mode ends.")
(define-obsolete-variable-alias 'allout-mode-deactivate-hook (define-obsolete-variable-alias 'allout-mode-deactivate-hook
'allout-mode-off-hook "24.1") 'allout-mode-off-hook "24.1")
(defvar allout-mode-deactivate-hook nil
"Hook run when allout mode ends.")
;;;_ = allout-exposure-category ;;;_ = allout-exposure-category
(defvar allout-exposure-category nil (defvar allout-exposure-category nil
"Symbol for use as allout invisible-text overlay category.") "Symbol for use as allout invisible-text overlay category.")
;;;_ = allout-exposure-change-functions ;;;_ = allout-exposure-change-functions
(define-obsolete-variable-alias 'allout-exposure-change-hook
'allout-exposure-change-functions "24.2")
(defcustom allout-exposure-change-functions nil (defcustom allout-exposure-change-functions nil
"Abnormal hook run after allout outline subtree exposure changes. "Abnormal hook run after allout outline subtree exposure changes.
It is run at the conclusion of `allout-flag-region'. It is run at the conclusion of `allout-flag-region'.
@ -1429,10 +1431,9 @@ This hook might be invoked multiple times by a single command."
:group 'allout :group 'allout
:version "24.2") :version "24.2")
(define-obsolete-variable-alias 'allout-exposure-change-hook
'allout-exposure-change-functions "24.2")
;;;_ = allout-structure-added-functions ;;;_ = allout-structure-added-functions
(define-obsolete-variable-alias 'allout-structure-added-hook
'allout-structure-added-functions "24.2")
(defcustom allout-structure-added-functions nil (defcustom allout-structure-added-functions nil
"Abnormal hook run after adding items to an Allout outline. "Abnormal hook run after adding items to an Allout outline.
Functions on the hook should take two arguments: Functions on the hook should take two arguments:
@ -1445,10 +1446,9 @@ This hook might be invoked multiple times by a single command."
:group 'allout :group 'allout
:version "24.2") :version "24.2")
(define-obsolete-variable-alias 'allout-structure-added-hook
'allout-structure-added-functions "24.2")
;;;_ = allout-structure-deleted-functions ;;;_ = allout-structure-deleted-functions
(define-obsolete-variable-alias 'allout-structure-deleted-hook
'allout-structure-deleted-functions "24.2")
(defcustom allout-structure-deleted-functions nil (defcustom allout-structure-deleted-functions nil
"Abnormal hook run after deleting subtrees from an Allout outline. "Abnormal hook run after deleting subtrees from an Allout outline.
Functions on the hook must take two arguments: Functions on the hook must take two arguments:
@ -1464,10 +1464,9 @@ This hook might be invoked multiple times by a single command."
:group 'allout :group 'allout
:version "24.2") :version "24.2")
(define-obsolete-variable-alias 'allout-structure-deleted-hook
'allout-structure-deleted-functions "24.2")
;;;_ = allout-structure-shifted-functions ;;;_ = allout-structure-shifted-functions
(define-obsolete-variable-alias 'allout-structure-shifted-hook
'allout-structure-shifted-functions "24.2")
(defcustom allout-structure-shifted-functions nil (defcustom allout-structure-shifted-functions nil
"Abnormal hook run after shifting items in an Allout outline. "Abnormal hook run after shifting items in an Allout outline.
Functions on the hook should take two arguments: Functions on the hook should take two arguments:
@ -1483,9 +1482,6 @@ This hook might be invoked multiple times by a single command."
:group 'allout :group 'allout
:version "24.2") :version "24.2")
(define-obsolete-variable-alias 'allout-structure-shifted-hook
'allout-structure-shifted-functions "24.2")
;;;_ = allout-after-copy-or-kill-hook ;;;_ = allout-after-copy-or-kill-hook
(defcustom allout-after-copy-or-kill-hook nil (defcustom allout-after-copy-or-kill-hook nil
"Normal hook run after copying outline text.." "Normal hook run after copying outline text.."

View file

@ -828,11 +828,11 @@ annotations."
"# Date: " (current-time-string) "\n")) "# Date: " (current-time-string) "\n"))
(define-obsolete-variable-alias 'bookmark-read-annotation-text-func
'bookmark-edit-annotation-text-func "23.1")
(defvar bookmark-edit-annotation-text-func 'bookmark-default-annotation-text (defvar bookmark-edit-annotation-text-func 'bookmark-default-annotation-text
"Function to return default text to use for a bookmark annotation. "Function to return default text to use for a bookmark annotation.
It takes one argument, the name of the bookmark, as a string.") It takes one argument, the name of the bookmark, as a string.")
(define-obsolete-variable-alias 'bookmark-read-annotation-text-func
'bookmark-edit-annotation-text-func "23.1")
(defvar bookmark-edit-annotation-mode-map (defvar bookmark-edit-annotation-mode-map
(let ((map (make-sparse-keymap))) (let ((map (make-sparse-keymap)))
@ -2164,11 +2164,11 @@ strings returned are not."
"Hook run at the end of loading library `bookmark.el'.") "Hook run at the end of loading library `bookmark.el'.")
;; Exit Hook, called from kill-emacs-hook ;; Exit Hook, called from kill-emacs-hook
(define-obsolete-variable-alias 'bookmark-exit-hooks
'bookmark-exit-hook "22.1")
(defvar bookmark-exit-hook nil (defvar bookmark-exit-hook nil
"Hook run when Emacs exits.") "Hook run when Emacs exits.")
(define-obsolete-variable-alias 'bookmark-exit-hooks 'bookmark-exit-hook "22.1")
(defun bookmark-exit-hook-internal () (defun bookmark-exit-hook-internal ()
"Save bookmark state, if necessary, at Emacs exit time. "Save bookmark state, if necessary, at Emacs exit time.
This also runs `bookmark-exit-hook'." This also runs `bookmark-exit-hook'."

View file

@ -199,6 +199,9 @@ commands.")
map) map)
"Local keymap for `Buffer-menu-mode' buffers.") "Local keymap for `Buffer-menu-mode' buffers.")
(define-obsolete-variable-alias 'buffer-menu-mode-hook
'Buffer-menu-mode-hook "23.1")
(define-derived-mode Buffer-menu-mode tabulated-list-mode "Buffer Menu" (define-derived-mode Buffer-menu-mode tabulated-list-mode "Buffer Menu"
"Major mode for Buffer Menu buffers. "Major mode for Buffer Menu buffers.
The Buffer Menu is invoked by the commands \\[list-buffers], \\[buffer-menu], and The Buffer Menu is invoked by the commands \\[list-buffers], \\[buffer-menu], and
@ -207,9 +210,6 @@ The Buffer Menu is invoked by the commands \\[list-buffers], \\[buffer-menu], an
(lambda (&optional _noconfirm) 'fast)) (lambda (&optional _noconfirm) 'fast))
(add-hook 'tabulated-list-revert-hook 'list-buffers--refresh nil t)) (add-hook 'tabulated-list-revert-hook 'list-buffers--refresh nil t))
(define-obsolete-variable-alias 'buffer-menu-mode-hook
'Buffer-menu-mode-hook "23.1")
(defun buffer-menu (&optional arg) (defun buffer-menu (&optional arg)
"Switch to the Buffer Menu. "Switch to the Buffer Menu.
By default, all buffers are listed except those whose names start By default, all buffers are listed except those whose names start

View file

@ -4825,6 +4825,7 @@ If several parents are listed, go to the first of them."
(set (make-local-variable 'widget-link-suffix) "")) (set (make-local-variable 'widget-link-suffix) ""))
(setq show-trailing-whitespace nil)) (setq show-trailing-whitespace nil))
(define-obsolete-variable-alias 'custom-mode-hook 'Custom-mode-hook "23.1")
(define-derived-mode Custom-mode nil "Custom" (define-derived-mode Custom-mode nil "Custom"
"Major mode for editing customization buffers. "Major mode for editing customization buffers.
@ -4873,7 +4874,6 @@ if that value is non-nil."
(Custom-mode)) (Custom-mode))
(make-obsolete 'custom-mode 'Custom-mode "23.1") (make-obsolete 'custom-mode 'Custom-mode "23.1")
(put 'custom-mode 'mode-class 'special) (put 'custom-mode 'mode-class 'special)
(define-obsolete-variable-alias 'custom-mode-hook 'Custom-mode-hook "23.1")
(add-to-list 'debug-ignored-errors "^Invalid face:? ") (add-to-list 'debug-ignored-errors "^Invalid face:? ")

View file

@ -145,6 +145,8 @@ backward compatibility.")
"Save status of Emacs when you exit." "Save status of Emacs when you exit."
:group 'frames) :group 'frames)
;; Maintained for backward compatibility
(define-obsolete-variable-alias 'desktop-enable 'desktop-save-mode "22.1")
;;;###autoload ;;;###autoload
(define-minor-mode desktop-save-mode (define-minor-mode desktop-save-mode
"Toggle desktop saving (Desktop Save mode). "Toggle desktop saving (Desktop Save mode).
@ -158,10 +160,6 @@ one session to another. See variable `desktop-save' and function
:global t :global t
:group 'desktop) :group 'desktop)
;; Maintained for backward compatibility
(define-obsolete-variable-alias 'desktop-enable
'desktop-save-mode "22.1")
(defun desktop-save-mode-off () (defun desktop-save-mode-off ()
"Disable `desktop-save-mode'. Provided for use in hooks." "Disable `desktop-save-mode'. Provided for use in hooks."
(desktop-save-mode 0)) (desktop-save-mode 0))

View file

@ -132,6 +132,8 @@ If nil, there is no maximum size."
:type '(choice (const :tag "no maximum" nil) integer) :type '(choice (const :tag "no maximum" nil) integer)
:group 'dired-x) :group 'dired-x)
;; For backward compatibility
(define-obsolete-variable-alias 'dired-omit-files-p 'dired-omit-mode "22.1")
(define-minor-mode dired-omit-mode (define-minor-mode dired-omit-mode
"Toggle omission of uninteresting files in Dired (Dired-Omit mode). "Toggle omission of uninteresting files in Dired (Dired-Omit mode).
With a prefix argument ARG, enable Dired-Omit mode if ARG is With a prefix argument ARG, enable Dired-Omit mode if ARG is
@ -157,9 +159,6 @@ See Info node `(dired-x) Omitting Variables' for more information."
(put 'dired-omit-mode 'safe-local-variable 'booleanp) (put 'dired-omit-mode 'safe-local-variable 'booleanp)
;; For backward compatibility
(define-obsolete-variable-alias 'dired-omit-files-p 'dired-omit-mode "22.1")
(defcustom dired-omit-files "^\\.?#\\|^\\.$\\|^\\.\\.$" (defcustom dired-omit-files "^\\.?#\\|^\\.$\\|^\\.\\.$"
"Filenames matching this regexp will not be displayed. "Filenames matching this regexp will not be displayed.
This only has effect when `dired-omit-mode' is t. See interactive function This only has effect when `dired-omit-mode' is t. See interactive function

View file

@ -179,6 +179,8 @@ and ends with a forward slash."
dir)) dir))
(define-obsolete-function-alias 'dirtrack-toggle 'dirtrack-mode "23.1")
(define-obsolete-variable-alias 'dirtrackp 'dirtrack-mode "23.1")
;;;###autoload ;;;###autoload
(define-minor-mode dirtrack-mode (define-minor-mode dirtrack-mode
"Toggle directory tracking in shell buffers (Dirtrack mode). "Toggle directory tracking in shell buffers (Dirtrack mode).
@ -198,10 +200,10 @@ directory."
(add-hook 'comint-preoutput-filter-functions 'dirtrack nil t) (add-hook 'comint-preoutput-filter-functions 'dirtrack nil t)
(remove-hook 'comint-preoutput-filter-functions 'dirtrack t))) (remove-hook 'comint-preoutput-filter-functions 'dirtrack t)))
(define-obsolete-function-alias 'dirtrack-toggle 'dirtrack-mode "23.1")
(define-obsolete-variable-alias 'dirtrackp 'dirtrack-mode "23.1")
(define-obsolete-function-alias 'dirtrack-debug-toggle 'dirtrack-debug-mode
"23.1")
(define-obsolete-variable-alias 'dirtrack-debug 'dirtrack-debug-mode "23.1")
(define-minor-mode dirtrack-debug-mode (define-minor-mode dirtrack-debug-mode
"Toggle Dirtrack debugging. "Toggle Dirtrack debugging.
With a prefix argument ARG, enable Dirtrack debugging if ARG is With a prefix argument ARG, enable Dirtrack debugging if ARG is
@ -211,11 +213,6 @@ the mode if ARG is omitted or nil."
(if dirtrack-debug-mode (if dirtrack-debug-mode
(display-buffer (get-buffer-create dirtrack-debug-buffer)))) (display-buffer (get-buffer-create dirtrack-debug-buffer))))
(define-obsolete-function-alias 'dirtrack-debug-toggle 'dirtrack-debug-mode
"23.1")
(define-obsolete-variable-alias 'dirtrack-debug 'dirtrack-debug-mode "23.1")
(defun dirtrack-debug-message (msg1 msg2) (defun dirtrack-debug-message (msg1 msg2)
"Insert strings at the end of `dirtrack-debug-buffer'." "Insert strings at the end of `dirtrack-debug-buffer'."
(when dirtrack-debug-mode (when dirtrack-debug-mode

View file

@ -233,15 +233,15 @@ returned unaltered."
(add-hook 'before-init-hook 'dos-reevaluate-defcustoms) (add-hook 'before-init-hook 'dos-reevaluate-defcustoms)
(define-obsolete-variable-alias
'register-name-alist 'dos-register-name-alist "24.1")
(defvar dos-register-name-alist (defvar dos-register-name-alist
'((ax . 0) (bx . 1) (cx . 2) (dx . 3) (si . 4) (di . 5) '((ax . 0) (bx . 1) (cx . 2) (dx . 3) (si . 4) (di . 5)
(cflag . 6) (flags . 7) (cflag . 6) (flags . 7)
(al . (0 . 0)) (bl . (1 . 0)) (cl . (2 . 0)) (dl . (3 . 0)) (al . (0 . 0)) (bl . (1 . 0)) (cl . (2 . 0)) (dl . (3 . 0))
(ah . (0 . 1)) (bh . (1 . 1)) (ch . (2 . 1)) (dh . (3 . 1)))) (ah . (0 . 1)) (bh . (1 . 1)) (ch . (2 . 1)) (dh . (3 . 1))))
(define-obsolete-variable-alias
'register-name-alist 'dos-register-name-alist "24.1")
(defun dos-make-register () (defun dos-make-register ()
(make-vector 8 0)) (make-vector 8 0))

View file

@ -62,8 +62,8 @@
(require 'eieio) (require 'eieio)
;;; Code: ;;; Code:
(defvar chart-mode-map (make-sparse-keymap) "Keymap used in chart mode.")
(define-obsolete-variable-alias 'chart-map 'chart-mode-map "24.1") (define-obsolete-variable-alias 'chart-map 'chart-mode-map "24.1")
(defvar chart-mode-map (make-sparse-keymap) "Keymap used in chart mode.")
(defvar chart-local-object nil (defvar chart-local-object nil
"Local variable containing the locally displayed chart object.") "Local variable containing the locally displayed chart object.")

View file

@ -97,10 +97,11 @@
;; Internal Variables ;; Internal Variables
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(define-obsolete-variable-alias 'generic-font-lock-defaults
'generic-font-lock-keywords "22.1")
(defvar generic-font-lock-keywords nil (defvar generic-font-lock-keywords nil
"Keywords for `font-lock-defaults' in a generic mode.") "Keywords for `font-lock-defaults' in a generic mode.")
(make-variable-buffer-local 'generic-font-lock-keywords) (make-variable-buffer-local 'generic-font-lock-keywords)
(define-obsolete-variable-alias 'generic-font-lock-defaults 'generic-font-lock-keywords "22.1")
;;;###autoload ;;;###autoload
(defvar generic-mode-list nil (defvar generic-mode-list nil

View file

@ -186,6 +186,8 @@ Return a value appropriate for `kill-buffer-query-functions' (which see)."
;; anything else (turn off) ;; anything else (turn off)
mode)))) mode))))
(define-obsolete-variable-alias 'emacs-lock-from-exiting
'emacs-lock-mode "24.1")
;;;###autoload ;;;###autoload
(define-minor-mode emacs-lock-mode (define-minor-mode emacs-lock-mode
"Toggle Emacs Lock mode in the current buffer. "Toggle Emacs Lock mode in the current buffer.
@ -245,8 +247,6 @@ Other values are interpreted as usual."
;;; Compatibility ;;; Compatibility
(define-obsolete-variable-alias 'emacs-lock-from-exiting 'emacs-lock-mode "24.1")
(defun toggle-emacs-lock () (defun toggle-emacs-lock ()
"Toggle `emacs-lock-from-exiting' for the current buffer." "Toggle `emacs-lock-from-exiting' for the current buffer."
(interactive) (interactive)

View file

@ -315,6 +315,7 @@ Otherwise, use `spell-region'."
;;; Global Keymaps ;;; Global Keymaps
;;; ;;;
(define-obsolete-variable-alias 'GOLD-map 'tpu-gold-map "23.1")
(defvar tpu-gold-map (defvar tpu-gold-map
(let ((map (make-keymap))) (let ((map (make-keymap)))
;; Previously we used escape sequences here. We now instead presume ;; Previously we used escape sequences here. We now instead presume
@ -494,7 +495,6 @@ Otherwise, use `spell-region'."
map) map)
"Maps the function keys on the VT100 keyboard preceded by PF1. "Maps the function keys on the VT100 keyboard preceded by PF1.
GOLD is the ASCII 7-bit escape sequence <ESC>OP.") GOLD is the ASCII 7-bit escape sequence <ESC>OP.")
(define-obsolete-variable-alias 'GOLD-map 'tpu-gold-map "23.1")
(defvar tpu-global-map (defvar tpu-global-map
(let ((map (make-sparse-keymap))) (let ((map (make-sparse-keymap)))

View file

@ -415,13 +415,13 @@ location of point in the current buffer."
;;;It is not useful to make this a local variable. ;;;It is not useful to make this a local variable.
;;;(put 'find-file-not-found-hooks 'permanent-local t) ;;;(put 'find-file-not-found-hooks 'permanent-local t)
(define-obsolete-variable-alias 'find-file-not-found-hooks
'find-file-not-found-functions "22.1")
(defvar find-file-not-found-functions nil (defvar find-file-not-found-functions nil
"List of functions to be called for `find-file' on nonexistent file. "List of functions to be called for `find-file' on nonexistent file.
These functions are called as soon as the error is detected. These functions are called as soon as the error is detected.
Variable `buffer-file-name' is already set up. Variable `buffer-file-name' is already set up.
The functions are called in the order given until one of them returns non-nil.") The functions are called in the order given until one of them returns non-nil.")
(define-obsolete-variable-alias 'find-file-not-found-hooks
'find-file-not-found-functions "22.1")
;;;It is not useful to make this a local variable. ;;;It is not useful to make this a local variable.
;;;(put 'find-file-hooks 'permanent-local t) ;;;(put 'find-file-hooks 'permanent-local t)
@ -435,6 +435,7 @@ functions are called."
:options '(auto-insert) :options '(auto-insert)
:version "22.1") :version "22.1")
(define-obsolete-variable-alias 'write-file-hooks 'write-file-functions "22.1")
(defvar write-file-functions nil (defvar write-file-functions nil
"List of functions to be called before writing out a buffer to a file. "List of functions to be called before writing out a buffer to a file.
If one of them returns non-nil, the file is considered already written If one of them returns non-nil, the file is considered already written
@ -451,13 +452,14 @@ coding system and setting mode bits. (See Info
node `(elisp)Saving Buffers'.) To perform various checks or node `(elisp)Saving Buffers'.) To perform various checks or
updates before the buffer is saved, use `before-save-hook'.") updates before the buffer is saved, use `before-save-hook'.")
(put 'write-file-functions 'permanent-local t) (put 'write-file-functions 'permanent-local t)
(define-obsolete-variable-alias 'write-file-hooks 'write-file-functions "22.1")
(defvar local-write-file-hooks nil) (defvar local-write-file-hooks nil)
(make-variable-buffer-local 'local-write-file-hooks) (make-variable-buffer-local 'local-write-file-hooks)
(put 'local-write-file-hooks 'permanent-local t) (put 'local-write-file-hooks 'permanent-local t)
(make-obsolete-variable 'local-write-file-hooks 'write-file-functions "22.1") (make-obsolete-variable 'local-write-file-hooks 'write-file-functions "22.1")
(define-obsolete-variable-alias 'write-contents-hooks
'write-contents-functions "22.1")
(defvar write-contents-functions nil (defvar write-contents-functions nil
"List of functions to be called before writing out a buffer to a file. "List of functions to be called before writing out a buffer to a file.
If one of them returns non-nil, the file is considered already written If one of them returns non-nil, the file is considered already written
@ -475,8 +477,6 @@ For hooks that _do_ pertain to the particular visited file, use
To perform various checks or updates before the buffer is saved, To perform various checks or updates before the buffer is saved,
use `before-save-hook'.") use `before-save-hook'.")
(make-variable-buffer-local 'write-contents-functions) (make-variable-buffer-local 'write-contents-functions)
(define-obsolete-variable-alias 'write-contents-hooks
'write-contents-functions "22.1")
(defcustom enable-local-variables t (defcustom enable-local-variables t
"Control use of local variables in files you visit. "Control use of local variables in files you visit.

View file

@ -1612,6 +1612,8 @@ itself as a pre-command hook."
(cancel-timer blink-cursor-timer) (cancel-timer blink-cursor-timer)
(setq blink-cursor-timer nil))) (setq blink-cursor-timer nil)))
(define-obsolete-variable-alias 'blink-cursor 'blink-cursor-mode "22.1")
(define-minor-mode blink-cursor-mode (define-minor-mode blink-cursor-mode
"Toggle cursor blinking (Blink Cursor mode). "Toggle cursor blinking (Blink Cursor mode).
With a prefix argument ARG, enable Blink Cursor mode if ARG is With a prefix argument ARG, enable Blink Cursor mode if ARG is
@ -1638,8 +1640,6 @@ terminals, cursor blinking is controlled by the terminal."
blink-cursor-delay blink-cursor-delay
'blink-cursor-start)))) 'blink-cursor-start))))
(define-obsolete-variable-alias 'blink-cursor 'blink-cursor-mode "22.1")
;;;; Key bindings ;;;; Key bindings
@ -1652,7 +1652,8 @@ terminals, cursor blinking is controlled by the terminal."
;; Misc. ;; Misc.
;; Only marked as obsolete in 24.2. ;; Only marked as obsolete in 24.2.
(define-obsolete-variable-alias 'automatic-hscrolling 'auto-hscroll-mode "22.1") (define-obsolete-variable-alias 'automatic-hscrolling
'auto-hscroll-mode "22.1")
(make-variable-buffer-local 'show-trailing-whitespace) (make-variable-buffer-local 'show-trailing-whitespace)

View file

@ -143,13 +143,13 @@ These are symbols with hooklike values whose names don't end in
`-hook' or `-hooks', from which `unload-feature' should try to remove `-hook' or `-hooks', from which `unload-feature' should try to remove
pertinent symbols.") pertinent symbols.")
(define-obsolete-variable-alias 'unload-hook-features-list
'unload-function-defs-list "22.2")
(defvar unload-function-defs-list nil (defvar unload-function-defs-list nil
"List of definitions in the Lisp library being unloaded. "List of definitions in the Lisp library being unloaded.
This is meant to be used by `FEATURE-unload-function'; see the This is meant to be used by `FEATURE-unload-function'; see the
documentation of `unload-feature' for details.") documentation of `unload-feature' for details.")
(define-obsolete-variable-alias 'unload-hook-features-list
'unload-function-defs-list "22.2")
(defun unload--set-major-mode () (defun unload--set-major-mode ()
(save-current-buffer (save-current-buffer

View file

@ -35,14 +35,14 @@
(eval-when-compile (require 'cl)) (eval-when-compile (require 'cl))
;;;###autoload
(define-obsolete-variable-alias 'disabled-command-hook
'disabled-command-function "22.1")
;;;###autoload ;;;###autoload
(defvar disabled-command-function 'disabled-command-function (defvar disabled-command-function 'disabled-command-function
"Function to call to handle disabled commands. "Function to call to handle disabled commands.
If nil, the feature is disabled, i.e., all commands work normally.") If nil, the feature is disabled, i.e., all commands work normally.")
;;;###autoload
(define-obsolete-variable-alias 'disabled-command-hook 'disabled-command-function "22.1")
;; It is ok here to assume that this-command is a symbol ;; It is ok here to assume that this-command is a symbol
;; because we won't get called otherwise. ;; because we won't get called otherwise.
;;;###autoload ;;;###autoload

View file

@ -829,6 +829,7 @@ The environment marked is the one that contains point or follows point."
st) st)
"Syntax table used in Metafont or MetaPost mode.") "Syntax table used in Metafont or MetaPost mode.")
(define-obsolete-variable-alias 'meta-mode-map 'meta-common-mode-map "24.1")
(defvar meta-common-mode-map (defvar meta-common-mode-map
(let ((map (make-sparse-keymap))) (let ((map (make-sparse-keymap)))
;; Comment Paragraphs: ;; Comment Paragraphs:
@ -858,7 +859,6 @@ The environment marked is the one that contains point or follows point."
;; (define-key map "\C-c\C-l" 'meta-recenter-output) ;; (define-key map "\C-c\C-l" 'meta-recenter-output)
map) map)
"Keymap used in Metafont or MetaPost mode.") "Keymap used in Metafont or MetaPost mode.")
(define-obsolete-variable-alias 'meta-mode-map 'meta-common-mode-map "24.1")
(easy-menu-define (easy-menu-define
meta-mode-menu meta-common-mode-map meta-mode-menu meta-common-mode-map

View file

@ -774,6 +774,8 @@ If you want to change this while speedbar is active, either use
(defvar speedbar-update-flag-disable nil (defvar speedbar-update-flag-disable nil
"Permanently disable changing of the update flag.") "Permanently disable changing of the update flag.")
(define-obsolete-variable-alias
'speedbar-syntax-table 'speedbar-mode-syntax-table "24.1")
(defvar speedbar-mode-syntax-table (defvar speedbar-mode-syntax-table
(let ((st (make-syntax-table))) (let ((st (make-syntax-table)))
;; Turn off paren matching around here. ;; Turn off paren matching around here.
@ -787,10 +789,9 @@ If you want to change this while speedbar is active, either use
(modify-syntax-entry ?\] " " st) (modify-syntax-entry ?\] " " st)
st) st)
"Syntax-table used on the speedbar.") "Syntax-table used on the speedbar.")
(define-obsolete-variable-alias
'speedbar-syntax-table 'speedbar-mode-syntax-table "24.1")
(define-obsolete-variable-alias 'speedbar-key-map 'speedbar-mode-map "24.1")
(defvar speedbar-mode-map (defvar speedbar-mode-map
(let ((map (make-keymap))) (let ((map (make-keymap)))
(suppress-keymap map t) (suppress-keymap map t)
@ -825,7 +826,6 @@ If you want to change this while speedbar is active, either use
(dframe-update-keymap map) (dframe-update-keymap map)
map) map)
"Keymap used in speedbar buffer.") "Keymap used in speedbar buffer.")
(define-obsolete-variable-alias 'speedbar-key-map 'speedbar-mode-map "24.1")
(defun speedbar-make-specialized-keymap () (defun speedbar-make-specialized-keymap ()
"Create a keymap for use with a speedbar major or minor display mode. "Create a keymap for use with a speedbar major or minor display mode.

View file

@ -274,6 +274,8 @@ will prompt for other arguments."
(and newtag (cdr cell) (not (member newtag (cdr cell))) (and newtag (cdr cell) (not (member newtag (cdr cell)))
(push newtag (cdr cell))))) (push newtag (cdr cell)))))
(define-obsolete-variable-alias
'reftex-index-map 'reftex-index-mode-map "24.1")
(defvar reftex-index-mode-map (defvar reftex-index-mode-map
(let ((map (make-sparse-keymap))) (let ((map (make-sparse-keymap)))
;; Index map ;; Index map
@ -377,8 +379,6 @@ will prompt for other arguments."
map) map)
"Keymap used for *Index* buffers.") "Keymap used for *Index* buffers.")
(define-obsolete-variable-alias
'reftex-index-map 'reftex-index-mode-map "24.1")
(defvar reftex-index-menu) (defvar reftex-index-menu)
@ -1179,6 +1179,8 @@ This gets refreshed in every phrases command.")
"Font lock keywords for reftex-index-phrases-mode.") "Font lock keywords for reftex-index-phrases-mode.")
(defvar reftex-index-phrases-font-lock-defaults nil (defvar reftex-index-phrases-font-lock-defaults nil
"Font lock defaults for reftex-index-phrases-mode.") "Font lock defaults for reftex-index-phrases-mode.")
(define-obsolete-variable-alias
'reftex-index-phrases-map 'reftex-index-phrases-mode-map "24.1")
(defvar reftex-index-phrases-mode-map (defvar reftex-index-phrases-mode-map
(let ((map (make-sparse-keymap))) (let ((map (make-sparse-keymap)))
;; Keybindings and Menu for phrases buffer ;; Keybindings and Menu for phrases buffer
@ -1244,8 +1246,6 @@ This gets refreshed in every phrases command.")
map) map)
"Keymap used for *toc* buffer.") "Keymap used for *toc* buffer.")
(define-obsolete-variable-alias
'reftex-index-phrases-map 'reftex-index-phrases-mode-map "24.1")
(defun reftex-index-phrase-selection-or-word (arg) (defun reftex-index-phrase-selection-or-word (arg)

View file

@ -71,6 +71,8 @@
(define-key map "-" 'negative-argument) (define-key map "-" 'negative-argument)
map)) map))
(define-obsolete-variable-alias
'reftex-select-label-map 'reftex-select-label-mode-map "24.1")
(defvar reftex-select-label-mode-map (defvar reftex-select-label-mode-map
(let ((map (make-sparse-keymap))) (let ((map (make-sparse-keymap)))
(set-keymap-parent map reftex-select-shared-map) (set-keymap-parent map reftex-select-shared-map)
@ -102,8 +104,6 @@
"Keymap used for *RefTeX Select* buffer, when selecting a label. "Keymap used for *RefTeX Select* buffer, when selecting a label.
This keymap can be used to configure the label selection process which is This keymap can be used to configure the label selection process which is
started with the command \\[reftex-reference].") started with the command \\[reftex-reference].")
(define-obsolete-variable-alias
'reftex-select-label-map 'reftex-select-label-mode-map "24.1")
(define-derived-mode reftex-select-label-mode fundamental-mode "LSelect" (define-derived-mode reftex-select-label-mode fundamental-mode "LSelect"
"Major mode for selecting a label in a LaTeX document. "Major mode for selecting a label in a LaTeX document.
@ -126,6 +126,8 @@ During a selection process, these are the local bindings.
;; We do not set a local map - reftex-select-item does this. ;; We do not set a local map - reftex-select-item does this.
) )
(define-obsolete-variable-alias
'reftex-select-bib-map 'reftex-select-bib-mode-map "24.1")
(defvar reftex-select-bib-mode-map (defvar reftex-select-bib-mode-map
(let ((map (make-sparse-keymap))) (let ((map (make-sparse-keymap)))
(set-keymap-parent map reftex-select-shared-map) (set-keymap-parent map reftex-select-shared-map)
@ -147,8 +149,6 @@ During a selection process, these are the local bindings.
"Keymap used for *RefTeX Select* buffer, when selecting a BibTeX entry. "Keymap used for *RefTeX Select* buffer, when selecting a BibTeX entry.
This keymap can be used to configure the BibTeX selection process which is This keymap can be used to configure the BibTeX selection process which is
started with the command \\[reftex-citation].") started with the command \\[reftex-citation].")
(define-obsolete-variable-alias
'reftex-select-bib-map 'reftex-select-bib-mode-map "24.1")
(define-derived-mode reftex-select-bib-mode fundamental-mode "BSelect" (define-derived-mode reftex-select-bib-mode fundamental-mode "BSelect"
"Major mode for selecting a citation key in a LaTeX document. "Major mode for selecting a citation key in a LaTeX document.

View file

@ -31,6 +31,7 @@
(require 'reftex) (require 'reftex)
;;; ;;;
(define-obsolete-variable-alias 'reftex-toc-map 'reftex-toc-mode-map "24.1")
(defvar reftex-toc-mode-map (defvar reftex-toc-mode-map
(let ((map (make-sparse-keymap))) (let ((map (make-sparse-keymap)))
@ -122,7 +123,6 @@
map) map)
"Keymap used for *toc* buffer.") "Keymap used for *toc* buffer.")
(define-obsolete-variable-alias 'reftex-toc-map 'reftex-toc-mode-map "24.1")
(defvar reftex-toc-menu) (defvar reftex-toc-menu)
(defvar reftex-last-window-height nil) (defvar reftex-last-window-height nil)

View file

@ -154,6 +154,8 @@ This variable is obsolete; instead of setting it to t, disable
;;; Variables that are not customizable. ;;; Variables that are not customizable.
(define-obsolete-variable-alias 'tooltip-hook 'tooltip-functions "23.1")
(defvar tooltip-functions nil (defvar tooltip-functions nil
"Functions to call to display tooltips. "Functions to call to display tooltips.
Each function is called with one argument EVENT which is a copy Each function is called with one argument EVENT which is a copy
@ -161,8 +163,6 @@ of the last mouse movement event that occurred. If one of these
functions displays the tooltip, it should return non-nil and the functions displays the tooltip, it should return non-nil and the
rest are not called.") rest are not called.")
(define-obsolete-variable-alias 'tooltip-hook 'tooltip-functions "23.1")
(defvar tooltip-timeout-id nil (defvar tooltip-timeout-id nil
"The id of the timeout started when Emacs becomes idle.") "The id of the timeout started when Emacs becomes idle.")

View file

@ -195,7 +195,10 @@ when this variable is set to nil.")
(defconst log-edit-maximum-comment-ring-size 32 (defconst log-edit-maximum-comment-ring-size 32
"Maximum number of saved comments in the comment ring.") "Maximum number of saved comments in the comment ring.")
(define-obsolete-variable-alias 'vc-comment-ring 'log-edit-comment-ring "22.1")
(defvar log-edit-comment-ring (make-ring log-edit-maximum-comment-ring-size)) (defvar log-edit-comment-ring (make-ring log-edit-maximum-comment-ring-size))
(define-obsolete-variable-alias 'vc-comment-ring-index
'log-edit-comment-ring-index "22.1")
(defvar log-edit-comment-ring-index nil) (defvar log-edit-comment-ring-index nil)
(defvar log-edit-last-comment-match "") (defvar log-edit-last-comment-match "")
@ -301,8 +304,6 @@ automatically."
(insert "\n")))) (insert "\n"))))
;; Compatibility with old names. ;; Compatibility with old names.
(define-obsolete-variable-alias 'vc-comment-ring 'log-edit-comment-ring "22.1")
(define-obsolete-variable-alias 'vc-comment-ring-index 'log-edit-comment-ring-index "22.1")
(define-obsolete-function-alias 'vc-previous-comment 'log-edit-previous-comment "22.1") (define-obsolete-function-alias 'vc-previous-comment 'log-edit-previous-comment "22.1")
(define-obsolete-function-alias 'vc-next-comment 'log-edit-next-comment "22.1") (define-obsolete-function-alias 'vc-next-comment 'log-edit-next-comment "22.1")
(define-obsolete-function-alias 'vc-comment-search-reverse 'log-edit-comment-search-backward "22.1") (define-obsolete-function-alias 'vc-comment-search-reverse 'log-edit-comment-search-backward "22.1")