vim-jp / vim-vimlparser

Vim script parser
Other
165 stars 25 forks source link

Support `:let=<<` with leading spaces before EOF #188

Closed lehmacdj closed 1 year ago

lehmacdj commented 2 years ago

Expert from the start of :h :let=<<:

                        *:let=<<* *:let-heredoc*
                        *E990* *E991* *E172* *E221*
:let {var-name} =<< [trim] {endmarker}
text...
text...
{endmarker}

This feature has been supported by vim/neovim since around 2019, it would be good if it could be supported by this library as well.

Note: I came here because this isn't parsed by vint and I'm assuming that they're using a fairly up to date version of this library. I did check issues / pull requests here and didn't see anything about this though.

lehmacdj commented 2 years ago

https://github.com/vim/vim/commit/f5842c5a533346c4ff41ff666e465c85f1de35d5 https://github.com/neovim/neovim/pull/11077

lehmacdj commented 2 years ago

Reduced scope of this, because I realized that let =<< is already implemented for the case where EOF is at the start of the line.