Jakson Alves de Aquino wrote:
> My Vim-R-plugin (#2628) includes a script to indent R code. I improved
> the script on February, 2011 and since then only one bug was reported
> (and fixed). So I believe that the script is mature enough to be
> considered for inclusion in Vim runtime directory.
>
> One remaining problem of the script is that it is slow. The
> indentation algorithm sometimes slowly goes backwards looking for an
> opening parenthesis or brace or for the beginning of a "for", "if" or
> "while" statement. This is necessary because the indentation level of
> a given line depends on the indentation level of the previous one, but
> the previous line is not always the line above. It's the line where
> the statement immediately above started.
>
> The indent/r.vim script is attached. I also attached a patch to
> doc/indent.txt.
Thanks, I'll include it.
If you make improvements, please send me the updated file.
--
BLACK KNIGHT: None shall pass.
ARTHUR: I have no quarrel with you, brave Sir knight, but I must cross
this bridge.
BLACK KNIGHT: Then you shall die.
"Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD
/// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language -- http://www.Zimbu.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
--
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