diff options
| author | Glenn Morris | 2015-06-15 20:41:54 -0400 |
|---|---|---|
| committer | Glenn Morris | 2015-06-15 20:41:54 -0400 |
| commit | c57b0e4b243a7a4a92549e833c7266b0be39f906 (patch) | |
| tree | 3bf3a7af262f27f8cf535594efe603013842cbc3 | |
| parent | 2f1f014b931ff570554522f17ae687cc8163c415 (diff) | |
| download | emacs-c57b0e4b243a7a4a92549e833c7266b0be39f906.tar.gz emacs-c57b0e4b243a7a4a92549e833c7266b0be39f906.zip | |
* lisp/macros.el (name-last-kbd-macro, kbd-macro-query)
(apply-macro-to-region-lines): Use user-error.
| -rw-r--r-- | lisp/macros.el | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/lisp/macros.el b/lisp/macros.el index bf1aa30d607..101f8b4a2a1 100644 --- a/lisp/macros.el +++ b/lisp/macros.el | |||
| @@ -39,14 +39,14 @@ The symbol's function definition becomes the keyboard macro string. | |||
| 39 | Such a \"function\" cannot be called from Lisp, but it is a valid editor command." | 39 | Such a \"function\" cannot be called from Lisp, but it is a valid editor command." |
| 40 | (interactive "SName for last kbd macro: ") | 40 | (interactive "SName for last kbd macro: ") |
| 41 | (or last-kbd-macro | 41 | (or last-kbd-macro |
| 42 | (error "No keyboard macro defined")) | 42 | (user-error "No keyboard macro defined")) |
| 43 | (and (fboundp symbol) | 43 | (and (fboundp symbol) |
| 44 | (not (stringp (symbol-function symbol))) | 44 | (not (stringp (symbol-function symbol))) |
| 45 | (not (vectorp (symbol-function symbol))) | 45 | (not (vectorp (symbol-function symbol))) |
| 46 | (error "Function %s is already defined and not a keyboard macro" | 46 | (user-error "Function %s is already defined and not a keyboard macro" |
| 47 | symbol)) | 47 | symbol)) |
| 48 | (if (string-equal symbol "") | 48 | (if (string-equal symbol "") |
| 49 | (error "No command name given")) | 49 | (user-error "No command name given")) |
| 50 | (fset symbol last-kbd-macro)) | 50 | (fset symbol last-kbd-macro)) |
| 51 | 51 | ||
| 52 | ;;;###autoload | 52 | ;;;###autoload |
| @@ -166,7 +166,7 @@ Your options are: \\<query-replace-map> | |||
| 166 | (interactive "P") | 166 | (interactive "P") |
| 167 | (or executing-kbd-macro | 167 | (or executing-kbd-macro |
| 168 | defining-kbd-macro | 168 | defining-kbd-macro |
| 169 | (error "Not defining or executing kbd macro")) | 169 | (user-error "Not defining or executing kbd macro")) |
| 170 | (if flag | 170 | (if flag |
| 171 | (let (executing-kbd-macro defining-kbd-macro) | 171 | (let (executing-kbd-macro defining-kbd-macro) |
| 172 | (recursive-edit)) | 172 | (recursive-edit)) |
| @@ -260,7 +260,7 @@ and then select the region of un-tablified names and use | |||
| 260 | (or macro | 260 | (or macro |
| 261 | (progn | 261 | (progn |
| 262 | (if (null last-kbd-macro) | 262 | (if (null last-kbd-macro) |
| 263 | (error "No keyboard macro has been defined")) | 263 | (user-error "No keyboard macro has been defined")) |
| 264 | (setq macro last-kbd-macro))) | 264 | (setq macro last-kbd-macro))) |
| 265 | (save-excursion | 265 | (save-excursion |
| 266 | (let ((end-marker (copy-marker bottom)) | 266 | (let ((end-marker (copy-marker bottom)) |