diff options
author | Karl Heuer <kwzh@gnu.org> | 1995-05-22 22:08:18 +0000 |
---|---|---|
committer | Karl Heuer <kwzh@gnu.org> | 1995-05-22 22:08:18 +0000 |
commit | a8e1fefac0eea6687454c78937396a85f88ff612 (patch) | |
tree | f98a194ca292c5fd0178ab99afbd7cff1c7e3c76 | |
parent | 98e05fae58f00a6cdf18e2185909e38cf0457fc0 (diff) | |
download | emacs-a8e1fefac0eea6687454c78937396a85f88ff612.tar.gz |
(edit-kbd-macro): Better error messages for undefined keys
or keys that are not keyboard macros.
-rw-r--r-- | lisp/edmacro.el | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lisp/edmacro.el b/lisp/edmacro.el index 8c9eaa2ed09..0255a675072 100644 --- a/lisp/edmacro.el +++ b/lisp/edmacro.el @@ -114,13 +114,16 @@ With a prefix argument, format the macro in a more concise way." ((eq cmd 'view-lossage) (setq mac (recent-keys)) (setq cmd 'last-kbd-macro)) + ((null cmd) + (error "Key sequence %s is not defined" (key-description keys))) ((symbolp cmd) (setq mac (symbol-function cmd))) (t (setq mac cmd) (setq cmd nil))) (unless (arrayp mac) - (error "Not a keyboard macro: %s" cmd)) + (error "Key sequence %s is not a keyboard macro" + (key-description keys))) (message "Formatting keyboard macro...") (let* ((oldbuf (current-buffer)) (mmac (edmacro-fix-menu-commands mac)) |