On Mar 22, 2014 10:08 PM, "LCD 47" <[email protected]> wrote:
>
> On 22 March 2014, Nikolay Pavlov <[email protected]> wrote:
> [...]
> > I am currently writing VimL parser for neovim (or for other project if
> > neovim fails: precise VimL parser is not only useful for vim fork),
> > this greatly improves the knowledge of Vim codebase.
> [...]
>
>     Tangentially related, you might want to take a look at vimlparser:
>
>         https://github.com/ynkdir/vim-vimlparser

Does not parse

    fu A()
        if 1
            return 1
    endf

. This code is correct.

Parses
    echo 1.2.3.4
as
    echo (1.2).(3.4)
. It is incorrect: 1.2.3.4 is the same as "1234": only string concatenation.

Though in any case it is better not to suggest any parser. First, they are
not written in C. Second, usually their purpose is something like linting
so they do not have to be almost perfectly compatible. Third, I use Vim
code as a reference and, sometimes, source of copy-paste.

>
>     There is also a lint checker based on it:
>
>         https://github.com/syngan/vim-vimlint
>
>     A formatter / pretty printer for VimL might be a nice by-product.

Currently my parser outputs valid VimL for testing purposes (in place of
some less readable, but unambiguous, AST representation).

>
>     /lcd
>
> --
> --
> You received this message from the "vim_dev" maillist.
> Do not top-post! Type your reply below the text you are replying to.
> For more information, visit http://www.vim.org/maillist.php
>
> ---
> You received this message because you are subscribed to the Google Groups
"vim_dev" group.
> To unsubscribe from this group and stop receiving emails from it, send an
email to [email protected].
> For more options, visit https://groups.google.com/d/optout.

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Raspunde prin e-mail lui