From: Eli Zaretskii Date: Sat, 29 Mar 2025 10:36:02 +0000 (+0300) Subject: Avoid warning when loading 'go-ts-mode' X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=7eecfc836697935bfe4c2ed6e2ac8ec8d35e5f55;p=emacs.git Avoid warning when loading 'go-ts-mode' * 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) --- diff --git a/lisp/progmodes/go-ts-mode.el b/lisp/progmodes/go-ts-mode.el index 6d59f6ed494..130e3829ae4 100644 --- a/lisp/progmodes/go-ts-mode.el +++ b/lisp/progmodes/go-ts-mode.el @@ -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.