Subject: bug#68899: Treesitter's forward-sexp-function

From: João Távora <[email-masked]>
Date: Sat, 3 Feb 2024 00:42:44 +0000

On Fri, Feb 2, 2024 at 9:47 PM João Távora <[email-masked]> wrote:

> Shouldn't the intervening treesit-end-of-thing go to the end of the
> current thing?, i.e. to the '('?  I think it should, at least judging
> from its docstring, and this patch makes that happen:
>
> -              (setq pos (funcall advance (if (> arg 0) next prev)))
> +              (setq pos (funcall advance (or (if (> arg 0) next prev)
> +                                             parent)))
>
> This doesn't seem to break tests, assuming it's not in these 3 there
> were skipped because I don't have the grammar installed.

Despite that, I think it's still wrong :-/ Now it moves too much,
i.e. it never stops moving.