Skip to content

Commit 2a64981

Browse files
authored
Avoid positional arguments to define-minor-mode (#105)
Back in Emacs-21.1, `define-minor-mode' grew keyword arguments to replace its old positional arguments. Starting with Emacs-28.1 warning will be omitted if positional arguments are still used. Using nil as explicit dummy values for the optional arguments and then subsequently using the corresponding keyword arguments to set the proper was never necessary and also didn't make much sense.
1 parent 4cfb46d commit 2a64981

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

lsp-treemacs.el

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -563,7 +563,6 @@ will be rendered an empty line between them."
563563
"Keymap for `lsp-treemacs-deps-list-mode'.")
564564

565565
(define-minor-mode lsp-treemacs-deps-list-mode ""
566-
nil nil nil
567566
:keymap lsp-treemacs-deps-list-mode-map
568567
:group 'lsp-treeemacs)
569568

@@ -866,7 +865,7 @@ will be rendered an empty line between them."
866865
"Keymap for `lsp-treemacs-generic-mode'")
867866

868867
(define-minor-mode lsp-treemacs-generic-mode "Treemacs generic mode."
869-
nil nil lsp-treemacs-generic-map)
868+
:keymap lsp-treemacs-generic-map)
870869

871870
(defun lsp-treemacs--handle-references (refs)
872871
(->> refs
@@ -1292,7 +1291,6 @@ With prefix 2 show both."
12921291
"Keymap for `lsp-treemacs-error-list-mode'.")
12931292

12941293
(define-minor-mode lsp-treemacs-error-list-mode ""
1295-
nil nil nil
12961294
:keymap lsp-treemacs-error-list-mode-map
12971295
:group 'lsp-treeemacs)
12981296

0 commit comments

Comments
 (0)