On 9 Nov 2008, at 14: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.
>
Well, you could try using the substitute() function (:he substitute() -
note the brackets) Something like this?

let var=substitute( someVar, "^.*\(what you're interested in\).*$",  
"\1", "" )

Regards, Andy

-- 
Andrew Long
andrew dot long at mac dot com


--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_use" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---

Reply via email to