[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] master 852ae26 14/22: Use quote instead of function to prevent co
From: |
Oleh Krehel |
Subject: |
[elpa] master 852ae26 14/22: Use quote instead of function to prevent compiler warnings |
Date: |
Fri, 16 Oct 2015 10:06:58 +0000 |
branch: master
commit 852ae2668a242e03b66a4cfd6182b0964cd9ed7e
Author: Oleh Krehel <address@hidden>
Commit: Oleh Krehel <address@hidden>
Use quote instead of function to prevent compiler warnings
* hydra.el (defhydra): In generated `define-key' statement use `quote'
instead of `function'.
* hydra-test.el (hydra-red-error): Update test.
This should fix the byte compiler warning for hydra-examples.el.
---
hydra-test.el | 58 +++++++++++++++++++++++++++-----------------------------
hydra.el | 2 +-
2 files changed, 29 insertions(+), 31 deletions(-)
diff --git a/hydra-test.el b/hydra-test.el
index dd6f31e..cc871a7 100644
--- a/hydra-test.el
+++ b/hydra-test.el
@@ -119,14 +119,14 @@ Call the head: `first-error'."
(setq hydra-curr-body-fn
(quote hydra-error/body)))
(condition-case err
- (progn
- (setq this-command
- (quote first-error))
- (call-interactively
- (function first-error)))
- ((quit error)
- (message "%S" err)
- (unless hydra-lv (sit-for 0.8))))
+ (progn
+ (setq this-command
+ (quote first-error))
+ (call-interactively
+ (function first-error)))
+ ((quit error)
+ (message "%S" err)
+ (unless hydra-lv (sit-for 0.8))))
(when hydra-is-helpful
(if hydra-lv
(lv-message
@@ -157,14 +157,14 @@ Call the head: `next-error'."
(setq hydra-curr-body-fn
(quote hydra-error/body)))
(condition-case err
- (progn
- (setq this-command
- (quote next-error))
- (call-interactively
- (function next-error)))
- ((quit error)
- (message "%S" err)
- (unless hydra-lv (sit-for 0.8))))
+ (progn
+ (setq this-command
+ (quote next-error))
+ (call-interactively
+ (function next-error)))
+ ((quit error)
+ (message "%S" err)
+ (unless hydra-lv (sit-for 0.8))))
(when hydra-is-helpful
(if hydra-lv
(lv-message
@@ -195,14 +195,14 @@ Call the head: `previous-error'."
(setq hydra-curr-body-fn
(quote hydra-error/body)))
(condition-case err
- (progn
- (setq this-command
- (quote previous-error))
- (call-interactively
- (function previous-error)))
- ((quit error)
- (message "%S" err)
- (unless hydra-lv (sit-for 0.8))))
+ (progn
+ (setq this-command
+ (quote previous-error))
+ (call-interactively
+ (function previous-error)))
+ ((quit error)
+ (message "%S" err)
+ (unless hydra-lv (sit-for 0.8))))
(when hydra-is-helpful
(if hydra-lv
(lv-message
@@ -222,14 +222,12 @@ Call the head: `previous-error'."
(define-key global-map (kbd "M-g")
nil))
(define-key global-map [134217831 104]
- (function
- hydra-error/first-error))
+ (quote hydra-error/first-error))
(define-key global-map [134217831 106]
- (function
- hydra-error/next-error))
+ (quote hydra-error/next-error))
(define-key global-map [134217831 107]
- (function
- hydra-error/previous-error))
+ (quote
+ hydra-error/previous-error))
(defun hydra-error/body nil
"Create a hydra with a \"M-g\" body and the heads:
diff --git a/hydra.el b/hydra.el
index 73d6621..fa4f641 100644
--- a/hydra.el
+++ b/hydra.el
@@ -1030,7 +1030,7 @@ result of `defhydra'."
(if (boundp bind)
(keymapp (symbol-value bind))
t))
- `(define-key ,bind ,final-key (function
,name)))
+ `(define-key ,bind ,final-key (quote
,name)))
(t
(error "Invalid :bind property `%S' for
head %S" bind head)))))))
heads))
- [elpa] master 2d45839 03/22: lv-window: split-window ignores window parameters, (continued)
- [elpa] master 2d45839 03/22: lv-window: split-window ignores window parameters, Oleh Krehel, 2015/10/16
- [elpa] master fca56c3 07/22: targets/hydra-init.el: Move, Oleh Krehel, 2015/10/16
- [elpa] master 1a13273 06/22: Allow to pause arbitrary hydras to the stack, Oleh Krehel, 2015/10/16
- [elpa] master adc2997 08/22: Allow for "_[_" and "_]_" in docs, Oleh Krehel, 2015/10/16
- [elpa] master 1acd5f6 05/22: hydra.el (hydra-face-blue): Customize for dark themes, Oleh Krehel, 2015/10/16
- [elpa] master c8b4749 09/22: Allow binding heads to "%", Oleh Krehel, 2015/10/16
- [elpa] master 7aa8187 13/22: Allow to specify :face for each head, Oleh Krehel, 2015/10/16
- [elpa] master df7b079 10/22: hydra.el (hydra-head-format): Customize the key formatting, Oleh Krehel, 2015/10/16
- [elpa] master 900ca34 04/22: Allow access to the current hydra body, Oleh Krehel, 2015/10/16
- [elpa] master 1e9276a 12/22: Remove trailing whitespace from :columns docstring, Oleh Krehel, 2015/10/16
- [elpa] master 852ae26 14/22: Use quote instead of function to prevent compiler warnings,
Oleh Krehel <=
- [elpa] master ea36afc 19/22: Allow "_", "!", and "&" as keys in docstrings, Oleh Krehel, 2015/10/16
- [elpa] master f58d356 17/22: Allow #'command syntax for heads, just to have it, Oleh Krehel, 2015/10/16
- [elpa] master 27b7f40 15/22: Make find-function work with defhydra, Oleh Krehel, 2015/10/16
- [elpa] master 3fb3168 18/22: hydra.el (hydra--format): Allow "@" key in the docs, Oleh Krehel, 2015/10/16
- [elpa] master 336602f 11/22: Add :columns option for hydra body, Oleh Krehel, 2015/10/16
- [elpa] master 4bf7f1c 21/22: Bump version, Oleh Krehel, 2015/10/16
- [elpa] master c5327e1 16/22: Declare dired-mark to silence byte-compiler, Oleh Krehel, 2015/10/16
- [elpa] master 39eed63 20/22: hydra.el (hydra-disable): Deactivate key-chord advice more, Oleh Krehel, 2015/10/16
- [elpa] master bfeccce 22/22: Merge commit '4bf7f1c9e46fb819c673e55d8a1891774e139f98' from hydra, Oleh Krehel, 2015/10/16