emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/which-key acaf543657 2/3: Use declare form instead of p


From: ELPA Syncer
Subject: [elpa] externals/which-key acaf543657 2/3: Use declare form instead of put, for clarity
Date: Sat, 2 Mar 2024 21:59:02 -0500 (EST)

branch: externals/which-key
commit acaf5436576f8ad8fa736c93e6ee618b4b371d55
Author: Jeremy Bryant <jb@jeremybryant.net>
Commit: Justin Burkett <justin@burkett.cc>

    Use declare form instead of put, for clarity
    
    * which-key.el (which-key-add-major-mode-key-based-replacements):
    Use declare form instead of put.
---
 which-key.el | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/which-key.el b/which-key.el
index 3eb27be8f1..c522f59a26 100644
--- a/which-key.el
+++ b/which-key.el
@@ -1129,6 +1129,7 @@ replacements are added to `which-key-replacement-alist'."
 The difference is that MODE specifies the `major-mode' that must
 be active for KEY-SEQUENCE and REPLACEMENT (MORE contains
 addition KEY-SEQUENCE REPLACEMENT pairs) to apply."
+  (declare (indent defun))
   ;; TODO: Make interactive
   (when (not (symbolp mode))
     (error "MODE should be a symbol corresponding to a value of major-mode"))
@@ -1155,8 +1156,6 @@ addition KEY-SEQUENCE REPLACEMENT pairs) to apply."
     (if (assq mode which-key--prefix-title-alist)
         (setcdr (assq mode which-key--prefix-title-alist) title-mode-alist)
       (push (cons mode title-mode-alist) which-key--prefix-title-alist))))
-(put 'which-key-add-major-mode-key-based-replacements
-     'lisp-indent-function 'defun)
 
 (defun which-key-define-key-recursively (map key def &optional at-root)
   "Recursively bind KEY in MAP to DEF on every level of MAP except the first.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]