aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorYuan Fu2024-10-28 19:30:52 -0700
committerYuan Fu2024-10-30 18:17:59 -0700
commitdf5ac0daf0fde7766ce607bd4c52a16650f3ac0f (patch)
tree1fb9c5e99f5a126a592e081323f72daabb3db096
parent7a3c10dcb56f7287158d155edba04bf80316fbe6 (diff)
downloademacs-df5ac0daf0fde7766ce607bd4c52a16650f3ac0f.tar.gz
emacs-df5ac0daf0fde7766ce607bd4c52a16650f3ac0f.zip
Fix the call to treesit-thing-defined-p
* lisp/treesit.el (treesit-defun-at-point): Add the necessary 2nd argument.
-rw-r--r--lisp/treesit.el4
1 files changed, 3 insertions, 1 deletions
diff --git a/lisp/treesit.el b/lisp/treesit.el
index 9ac470691d6..2518204ce93 100644
--- a/lisp/treesit.el
+++ b/lisp/treesit.el
@@ -2823,7 +2823,9 @@ is `nested'.
2823 2823
2824Return nil if `treesit-defun-type-regexp' isn't set and `defun' 2824Return nil if `treesit-defun-type-regexp' isn't set and `defun'
2825isn't defined in `treesit-thing-settings'." 2825isn't defined in `treesit-thing-settings'."
2826 (when (or treesit-defun-type-regexp (treesit-thing-defined-p 'defun)) 2826 (when (or treesit-defun-type-regexp
2827 (treesit-thing-defined-p
2828 'defun (treesit-language-at (point))))
2827 (treesit-thing-at-point 2829 (treesit-thing-at-point
2828 (or treesit-defun-type-regexp 'defun) treesit-defun-tactic))) 2830 (or treesit-defun-type-regexp 'defun) treesit-defun-tactic)))
2829 2831