1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-15 10:30:25 -08:00

Fix usage of 'treesit-defun-type-regexp' in treesit-tests.

* test/src/treesit-tests.el (treesit--ert-test-defun-navigation):
Replace 'treesit-defun-type-regexp' with
'(or treesit-defun-type-regexp 'defun)' that fixes the tests
for ts-modes that set up the 'defun' thing instead of
'treesit-defun-type-regexp'.
This commit is contained in:
Juri Linkov 2025-06-25 19:45:54 +03:00
parent 9ebcbf93ba
commit 789a6b9693

View file

@ -1141,7 +1141,8 @@ and \"]\"."
(if-let* ((pos (funcall
#'treesit-navigate-thing
(point) (car conf) (cdr conf)
treesit-defun-type-regexp tactic)))
(or treesit-defun-type-regexp 'defun)
tactic)))
(save-excursion
(goto-char pos)
(funcall treesit-defun-skipper)