[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/bind-map b47b98455f 87/97: Simplify macro exp. for bind-ma
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/bind-map b47b98455f 87/97: Simplify macro exp. for bind-mapfor-mode-inherit |
Date: |
Thu, 20 Jan 2022 07:59:29 -0500 (EST) |
branch: elpa/bind-map
commit b47b98455ff015cc408c1ce55fb3b6c259067f17
Author: justbur <justin@burkett.cc>
Commit: justbur <justin@burkett.cc>
Simplify macro exp. for bind-mapfor-mode-inherit
---
bind-map.el | 29 ++++++++++++++---------------
1 file changed, 14 insertions(+), 15 deletions(-)
diff --git a/bind-map.el b/bind-map.el
index 2a620eb690..b92f5a9799 100644
--- a/bind-map.el
+++ b/bind-map.el
@@ -389,21 +389,20 @@ and :evil-states. All others must be declared explicitly."
(minor-modes (plist-get args :minor-modes))
(major-modes (plist-get args :major-modes))
(bindings (plist-get args :bindings)))
- `(progn
- (if (and (null ',minor-modes)
- (null ',major-modes))
- (user-error "bind-map-for-modes-derived called without \
-reference to :major-modes or :minor-modes")
- (bind-map ,map
- :prefix-cmd ,(plist-get args :prefix-cmd)
- :override-mode-name ,(plist-get args :override-mode-name)
- :minor-modes ,minor-modes
- :major-modes ,major-modes
- :bindings ,bindings
- ,@(bind-map--get-prop :override-minor-modes args parent-args)
- ,@(bind-map--get-prop :keys args parent-args)
- ,@(bind-map--get-prop :evil-keys args parent-args)
- ,@(bind-map--get-prop :evil-states args parent-args))))))
+ (when (and (null minor-modes)
+ (null major-modes))
+ (user-error "bind-map-for-modes-derived called without \
+reference to :major-modes or :minor-modes"))
+ `(bind-map ,map
+ :prefix-cmd ,(plist-get args :prefix-cmd)
+ :override-mode-name ,(plist-get args :override-mode-name)
+ :minor-modes ,minor-modes
+ :major-modes ,major-modes
+ :bindings ,bindings
+ ,@(bind-map--get-prop :override-minor-modes args parent-args)
+ ,@(bind-map--get-prop :keys args parent-args)
+ ,@(bind-map--get-prop :evil-keys args parent-args)
+ ,@(bind-map--get-prop :evil-states args parent-args))))
;;;###autoload
(defmacro bind-map-for-major-mode (major-mode-sym &rest args)
- [nongnu] elpa/bind-map b0b9e18947 66/97: Revert last commit, (continued)
- [nongnu] elpa/bind-map b0b9e18947 66/97: Revert last commit, ELPA Syncer, 2022/01/20
- [nongnu] elpa/bind-map f51d4b0c0d 79/97: Add bind-map-for-modes-derived, ELPA Syncer, 2022/01/20
- [nongnu] elpa/bind-map 21b7ba7eca 30/97: Fix some docstrings, ELPA Syncer, 2022/01/20
- [nongnu] elpa/bind-map cc1db8958c 64/97: Version 0.1, ELPA Syncer, 2022/01/20
- [nongnu] elpa/bind-map 988f14eb77 65/97: Use evil-define-minor-mode-key for minor-mode keys, ELPA Syncer, 2022/01/20
- [nongnu] elpa/bind-map 292794739c 71/97: Fix incorrect check of override mode in local hook, ELPA Syncer, 2022/01/20
- [nongnu] elpa/bind-map b187069313 22/97: Add short versions for single major/minor mode, ELPA Syncer, 2022/01/20
- [nongnu] elpa/bind-map d45971cd40 46/97: Use minor mode for overriding behavior, ELPA Syncer, 2022/01/20
- [nongnu] elpa/bind-map 8d6b489feb 50/97: Add some basic tests, ELPA Syncer, 2022/01/20
- [nongnu] elpa/bind-map 24d453a1e8 55/97: Call evil-normalize-maps for evil-keys, ELPA Syncer, 2022/01/20
- [nongnu] elpa/bind-map b47b98455f 87/97: Simplify macro exp. for bind-mapfor-mode-inherit,
ELPA Syncer <=
- [nongnu] elpa/bind-map 078c522f6e 93/97: Fix Makefile, ELPA Syncer, 2022/01/20
- [nongnu] elpa/bind-map ffe5e63617 92/97: Version 1.1.0, ELPA Syncer, 2022/01/20
- [nongnu] elpa/bind-map 46438e30c8 02/97: README formatting, ELPA Syncer, 2022/01/20
- [nongnu] elpa/bind-map f835ed39fe 06/97: Minor changes, ELPA Syncer, 2022/01/20
- [nongnu] elpa/bind-map 8dea8e8f91 10/97: Grammatical fix in README, ELPA Syncer, 2022/01/20
- [nongnu] elpa/bind-map e5647f14cf 11/97: Clarify modes in README, ELPA Syncer, 2022/01/20
- [nongnu] elpa/bind-map c8fa049b70 13/97: Update Commentary section to match README, ELPA Syncer, 2022/01/20
- [nongnu] elpa/bind-map 281a56c332 16/97: Fix major-mode-list, ELPA Syncer, 2022/01/20
- [nongnu] elpa/bind-map db9d72efcd 31/97: Better version of bind-map-key, ELPA Syncer, 2022/01/20
- [nongnu] elpa/bind-map 76f742191b 24/97: Add gitignore, ELPA Syncer, 2022/01/20