On 11月10日, 上午3时44分, Tony Mechelynck <[EMAIL PROTECTED]>
wrote:
> On 09/11/08 15:31, 703designs wrote:
>
> > If I use a regex in match(), which I always do, how do I deal with any
> > captured patters, e.g "^\(\s*\)" ? I'd like to store them to local
> > vars.
>
> > Thomas
>
> See :help matchlist()
>
> I found it using :help match*()<Tab> (with 'wildmenu' on)

and sometimes matchstr, if you just want get one patter. you can
write:
let str = matchstr(str, "^\zs\s*\ze")

> Best regards,
> Tony.
> --
> It's more than magnificent -- it's mediocre.
>                 -- Sam Goldwyn
--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_use" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---

Reply via email to