aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKarl Heuer <[email protected]>1995-05-22 22:08:18 +0000
committerKarl Heuer <[email protected]>1995-05-22 22:08:18 +0000
commita8e1fefac0eea6687454c78937396a85f88ff612 (patch)
treef98a194ca292c5fd0178ab99afbd7cff1c7e3c76
parent98e05fae58f00a6cdf18e2185909e38cf0457fc0 (diff)
(edit-kbd-macro): Better error messages for undefined keys
or keys that are not keyboard macros.
-rw-r--r--lisp/edmacro.el5
1 files changed, 4 insertions, 1 deletions
diff --git a/lisp/edmacro.el b/lisp/edmacro.el
index 8c9eaa2ed0..0255a67507 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))