neovim / tree-sitter-vimdoc

Tree-sitter parser for Vim help files
Apache License 2.0
97 stars 13 forks source link

issue with angle-brackets in change.txt #67

Closed bugsbugsbux closed 1 year ago

bugsbugsbux commented 1 year ago

reproduce: :help < How it's actually displayed:

SHIFTING LINES LEFT OR RIGHT                            shift-left-right

                                                        <
{motion}                Shift {motion} lines one 'shiftwidth' leftwards.

                        If the 'shiftwidth' option is set to zero, the amount
                        of indent is calculated at the first non-blank
                        character in the line.
                                                        <<
<                       Shift [count] lines one 'shiftwidth' leftwards.

                                                        v_<
{Visual}[count]<        Shift the highlighted lines [count] 'shiftwidth'

I hope this is the right place to report this...

clason commented 1 year ago

I don't see any difference between this parser and legacy syntax?

bugsbugsbux commented 1 year ago

so, you mean, i have to raise this issue with neovim/neovim?

clason commented 1 year ago

I mean, I don't see an actual issue here?

bugsbugsbux commented 1 year ago

it should be:

SHIFTING LINES LEFT OR RIGHT                            shift-left-right

                                                        <
<{motion}                Shift {motion} lines one 'shiftwidth' leftwards.

                        If the 'shiftwidth' option is set to zero, the amount
                        of indent is calculated at the first non-blank
                        character in the line.
                                                        <<
<<                       Shift [count] lines one 'shiftwidth' leftwards.

                                                        v_<
{Visual}[count]<        Shift the highlighted lines [count] 'shiftwidth'
clason commented 1 year ago

That's what I see. Make sure you are using the latest version of this parser and the help files.

(This parser is not meant to reproduce every single quirk of the syntax files: if something in a help file is not easily parseable, the help file is changed instead. In this case, we have replaced < -- which marks the end of a code block -- with < (note the space).)

clason commented 1 year ago

That being said, it might be possible to tighten the codeblock terminator token to <\n @justinmk ?

bugsbugsbux commented 1 year ago

using the latest version of this parser

I used the lastest version, but it seems upgrading my neovim installation fixed it; i apoligize.