On 11/12/08 09:24, Jürgen Krämer wrote:
> Hi,
>
> Robert Mark Bram wrote:
>> Can anyone guide me as to how I can modify the ".*" in the above
>> expression to deal with new line chars too?
>
> just prefix it with "\_", i.e., make it "\_.*".
>
> And you probably want to put backslashes before "(", ")", and "+".
>
> Regards,
> Jürgen
>

Yes, and beware that the star multi is greedy, i.e., if you have several 
matched begin- and end-patterns in the file, begin\_.*end will always 
match with the _last_ "end" in the file, gobbling up any number of 
begin-end blocks in between. \_.{-} will match as few of "anything 
including a line break" as possible, which might be better suited to 
your needs here. See ":help /multi".


Best regards,
Tony.
-- 
The debate rages on: Is PL/I Bachtrian or Dromedary?

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

Reply via email to