fix(lsp,tree-sitter): void-function lsp!/tree-sitter! errors
These are autodefs, meaning they should be defined whether or not the containing module is enabled, but they should no-op when it's disabled, by defining a no-op macro with the same name. However, lsp! and tree-sitter! are meant to be used as hooks, and you can't use macros as hooks, so you get void-function errors when they are used as such. This ensures they are properly defined as no-op functions in those cases. I.e. ;;;###autodef FORM FORM is used instead of a no-op macro if the parent module is disabled.
This commit is contained in:
parent
23b289b9a5
commit
c06040338a
2 changed files with 2 additions and 2 deletions
|
@ -1,6 +1,6 @@
|
||||||
;;; tools/lsp/autoload/common.el -*- lexical-binding: t; -*-
|
;;; tools/lsp/autoload/common.el -*- lexical-binding: t; -*-
|
||||||
|
|
||||||
;;;###autodef
|
;;;###autodef (fset 'lsp! #'ignore)
|
||||||
(defun lsp! ()
|
(defun lsp! ()
|
||||||
"Dispatch to call the currently used lsp client entrypoint"
|
"Dispatch to call the currently used lsp client entrypoint"
|
||||||
(interactive)
|
(interactive)
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
;;; tools/tree-sitter/autoload.el -*- lexical-binding: t; -*-
|
;;; tools/tree-sitter/autoload.el -*- lexical-binding: t; -*-
|
||||||
|
|
||||||
;;;###autodef
|
;;;###autodef (fset 'tree-sitter! #'ignore)
|
||||||
(defun tree-sitter! ()
|
(defun tree-sitter! ()
|
||||||
(interactive)
|
(interactive)
|
||||||
(turn-on-tree-sitter-mode))
|
(turn-on-tree-sitter-mode))
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue