]> git.eshelyaron.com Git - emacs.git/commitdiff
Avoid warning when loading 'go-ts-mode'
authorEli Zaretskii <eliz@gnu.org>
Sat, 29 Mar 2025 10:36:02 +0000 (13:36 +0300)
committerEshel Yaron <me@eshelyaron.com>
Mon, 31 Mar 2025 08:32:32 +0000 (10:32 +0200)
* lisp/progmodes/go-ts-mode.el (treesit-ready-p): Silence the
warning if the gomod language library is not installed.
(Bug#77213)

(cherry picked from commit 26873d5028ed8aa0e2fc56c7d6ed3b43ff976d3c)

lisp/progmodes/go-ts-mode.el

index 6d59f6ed4949e346aa5200b202ecd26033f6e0c8..130e3829ae4bd49eb4ff5aab2ed673bdcae834e3 100644 (file)
@@ -601,7 +601,7 @@ what the parent of the node would be if it were a node."
 
 (derived-mode-add-parents 'go-mod-ts-mode '(go-mod-mode))
 
-(if (treesit-ready-p 'gomod)
+(if (treesit-ready-p 'gomod t)
     (add-to-list 'auto-mode-alist '("/go\\.mod\\'" . go-mod-ts-mode)))
 
 ;;;; go.work support.