# HG changeset patch # User Richard M. Stallman # Date 1040501931 0 # Node ID 36f7a48a9735efd45780cc7a8f01130bd7b275a4 # Parent bb52f186fa1e56b5bd31dda355c47244edfc6547 (command-history-map): Move definition up. diff -r bb52f186fa1e -r 36f7a48a9735 lisp/chistory.el --- a/lisp/chistory.el Sat Dec 21 20:18:03 2002 +0000 +++ b/lisp/chistory.el Sat Dec 21 20:18:51 2002 +0000 @@ -125,6 +125,16 @@ (error "No command history") (command-history-mode))))) +(defvar command-history-map nil) +(unless command-history-map + (setq command-history-map (make-sparse-keymap)) + (set-keymap-parent command-history-map lisp-mode-shared-map) + (suppress-keymap command-history-map) + (define-key command-history-map "x" 'command-history-repeat) + (define-key command-history-map "\n" 'next-line) + (define-key command-history-map "\r" 'next-line) + (define-key command-history-map "\177" 'previous-line)) + (defun command-history-mode () "Major mode for listing and repeating recent commands. @@ -149,16 +159,6 @@ :type 'hook :group 'chistory) -(defvar command-history-map nil) -(unless command-history-map - (setq command-history-map (make-sparse-keymap)) - (set-keymap-parent command-history-map lisp-mode-shared-map) - (suppress-keymap command-history-map) - (define-key command-history-map "x" 'command-history-repeat) - (define-key command-history-map "\n" 'next-line) - (define-key command-history-map "\r" 'next-line) - (define-key command-history-map "\177" 'previous-line)) - (defun command-history-repeat () "Repeat the command shown on the current line. The buffer for that command is the previous current buffer."