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

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

bug#61260: 29.0.60; wrong indentation will break the highlight on yaml-t


From: Randy Taylor
Subject: bug#61260: 29.0.60; wrong indentation will break the highlight on yaml-ts-mode
Date: Wed, 08 Feb 2023 13:33:18 +0000

On Friday, February 3rd, 2023 at 20:20, Eason Huang <aqua0210@foxmail.com> 
wrote:
> 
> Hi Emacs dev team,
> 
> I found that when editing yaml file with yaml-ts-mode, the buffer
> highlight will be break when the indentation of current line is wrong.
> 
> Steps to reproduce:
> 
> 1. Start Emacs with `emacs -Q`
> 2. Open any a yaml file, such as `C-x, C-f ~/test.yaml`
> 3. M-x yaml-ts-mode, enable the yaml-ts-mode on test.yaml buffer
> 4. input the code below in the test.yaml buffer
> `values: a: 10 b: 20 c: 30`
> 5. so far so good.
> 6. if the line 2 have a wrong indentation, such as four spaces in stead of
> two spaces. Now the hightlight of line 3 and line 4 will be break
> `values: a: 10 b: 20 c: 30`
> 
> The commit I built Emacs is f25c15ceb7d from emacs-29 branch.

Hi, and thanks for the report.

This is because the second incantation:
```
values:
    a: 10
  b: 20
  c: 30
```

is not valid YAML, and the parser reports an error.

Therefore I'm closing this bug since I don't think there's anything we can do 
here.





reply via email to

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