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

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

[elpa] externals/leaf eb8ce41 10/18: Merge pull request #490 from zonuex


From: Stefan Monnier
Subject: [elpa] externals/leaf eb8ce41 10/18: Merge pull request #490 from zonuexe/refactor/typing-leaf-defaults
Date: Wed, 2 Jun 2021 18:28:02 -0400 (EDT)

branch: externals/leaf
commit eb8ce411d4e839ed0f52968e4007559eb7d2553b
Merge: d695f24 9e9d06c
Author: Naoya Yamashita <conao3@gmail.com>
Commit: GitHub <noreply@github.com>

    Merge pull request #490 from zonuexe/refactor/typing-leaf-defaults
    
    Add custom type for leaf-defaults and change leaf-system-defaults to defvar
---
 leaf.el | 22 ++++++++++++++--------
 1 file changed, 14 insertions(+), 8 deletions(-)

diff --git a/leaf.el b/leaf.el
index 64baac2..2b1a2a1 100644
--- a/leaf.el
+++ b/leaf.el
@@ -5,7 +5,7 @@
 ;; Author: Naoya Yamashita <conao3@gmail.com>
 ;; Maintainer: Naoya Yamashita <conao3@gmail.com>
 ;; Keywords: lisp settings
-;; Version: 4.4.5
+;; Version: 4.4.6
 ;; URL: https://github.com/conao3/leaf.el
 ;; Package-Requires: ((emacs "24.1"))
 
@@ -361,15 +361,21 @@ Sort by `leaf-sort-leaf--values-plist' in this order.")
 
 (defcustom leaf-defaults '()
   "The value that are interpreted as specified for all `leaf' blocks."
-  :type 'sexp
+  :type '(plist :key-type (choice (const :leaf-autoload)
+                                  (const :leaf-defer)
+                                  (const :leaf-protect)
+                                  (const :leaf-defun)
+                                  (const :leaf-defvar)
+                                  (const :leaf-path)
+                                  (symbol :tag "A keyword in `M-x 
leaf-available-keywords`"))
+                :value-type (choice boolean
+                                    (sexp :tag "Default value of the 
keyword")))
   :group 'leaf)
 
-(defcustom leaf-system-defaults (leaf-list
-                                 :leaf-autoload t :leaf-defer t :leaf-protect t
-                                 :leaf-defun t :leaf-defvar t :leaf-path t)
-  "The value for all `leaf' blocks for leaf system."
-  :type 'sexp
-  :group 'leaf)
+(defvar leaf-system-defaults (list
+                              :leaf-autoload t :leaf-defer t :leaf-protect t
+                              :leaf-defun t :leaf-defvar t :leaf-path t)
+  "The value for all `leaf' blocks for leaf system.")
 
 (defcustom leaf-defer-keywords (list
                                 :bind :bind*



reply via email to

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