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

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

bug#66732: tree-sitter fontification doesn't update multi-line syntax re


From: Dmitry Gutov
Subject: bug#66732: tree-sitter fontification doesn't update multi-line syntax reliably
Date: Wed, 25 Oct 2023 02:15:30 +0300
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.13.0

Hi Dominik,

On 24/10/2023 17:22, Dominik Honnef wrote:
Steps to reproduce:

1. Start emacs -q
2. Clear the scratch buffer
3. Switch to c-ts-mode
4. Type the following:

     /* foo
     bar
     baz
     */

Notice the following:

1. tree-sitter will not parse the buffer contents as a comment until the
closing comment marker is typed (not an issue per se.)

2. When you type the closing comment marker, only that line will be
fontified.

3. Moving to the previous line will refontify the whole comment.

Similarly, removing the closing comment marker will not instantly
refontify the buffer, either.

The expected behavior would be for the whole comment to be refontified
immediately after typing the closing comment marker.

Other buffer contents often lead to even worse refontifying, where even
motion will not fix things.

Can repro.

Only with 'emacs -Q', though (note to others who will try).





reply via email to

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