[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: Syntax and redundancy
- From: "Aaron Brown" <aaron-lua@...>
- Date: Mon, 29 Aug 2005 14:38:17 -0400
David Olofson wrote:
> However, I can't remember seeing an editor with a
> "highlight matching keyword" feature...
Rici Lake wrote:
> The standard vim lua highlighter has the nice feature of
> colouring the end in function ... end a different colour
> than the end in do ... end.
Also, Vim's matchit plugin allows jumping between control
flow keywords with the same key ("%") that normally jumps to
the matching parenthesis. Do ":help matchit" for more
According to the documentation it supports Lua
out-of-the-box, but my copy didn't, so I had to add:
au FileType lua if !exists("b:match_words") |
\ let b:match_words =
\ '\<\%(do\|function\|if\)\>:' .
\ '\<\%(return\|else\|elseif\)\>:' .
\ '\<end\>,' .
\ | endif