mirror of
git://git.sv.gnu.org/emacs.git
synced 2026-02-16 17:24:23 +00:00
Make M-x show what aliases point to (Bug#43300)
* lisp/simple.el (read-extended-command--annotation): Show an annotation for aliases saying what it points to.
This commit is contained in:
parent
1b0a922a19
commit
06d86b954d
1 changed files with 5 additions and 2 deletions
|
|
@ -1887,8 +1887,11 @@ to get different commands to edit and resubmit."
|
|||
(defun read-extended-command--annotation (command-name)
|
||||
(let* ((fun (and (stringp command-name) (intern-soft command-name)))
|
||||
(binding (where-is-internal fun overriding-local-map t))
|
||||
(obsolete (get fun 'byte-obsolete-info)))
|
||||
(cond (obsolete
|
||||
(obsolete (get fun 'byte-obsolete-info))
|
||||
(alias (symbol-function fun)))
|
||||
(cond ((symbolp alias)
|
||||
(format " (%s)" alias))
|
||||
(obsolete
|
||||
(format " (%s)" (car obsolete)))
|
||||
((and binding (not (stringp binding)))
|
||||
(format " (%s)" (key-description binding))))))
|
||||
|
|
|
|||
Loading…
Reference in a new issue