bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#62158: treesit-end-of-defun error


From: Juri Linkov
Subject: bug#62158: treesit-end-of-defun error
Date: Mon, 20 Mar 2023 20:21:38 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/30.0.50 (x86_64-pc-linux-gnu)

close 62158 29.0.60
thanks

>>> The fix seems to be easy:
>>> 
>>> diff --git a/lisp/treesit.el b/lisp/treesit.el
>>> index c118f5d52a4..b271a1f0c4b 100644
>>> --- a/lisp/treesit.el
>>> +++ b/lisp/treesit.el
>>> @@ -1882,6 +1882,7 @@ treesit-end-of-defun
>>> `treesit-defun-skipper'."
>>>   (interactive "^p\nd")
>>>   (let ((orig-point (point)))
>>> +    (if (or (null arg) (= arg 0)) (setq arg 1))
>>>     (catch 'done
>>>       (dotimes (_ 2) ; Not making progress is better than infloop.
>>> 
>>> But I'm not quite sure if that is what we want to do.
>
> This looks good to me.

So Dmitry's fix is pushed to emacs-29.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]