In Vim regex, you should use '\|' instead of just '|': syntax match myTag /Mon\|Tue\|Wed/
Most times, you can use a keyword instead, they are faster: syntax case match syntax keyword myTag Mon Tue Wed regards, Peter --- On Mon, 17/8/09, Arco <[email protected]> wrote: > From: Arco <[email protected]> > Subject: Syntax Highlighting / Regexp > To: "vim_use" <[email protected]> > Received: Monday, 17 August, 2009, 2:07 PM > > I'm setting up syntax highlighting for a custom file > type. Everything > works great except this regexp: > > syntax match myTag /Mon|Tue|Wed/ > > 'myTag' is supposed to match "Mon" or "Tue" or "Wed" > - but it won't > work. > > My workaround is to have three statements in my > <lang>.vim syntax > file: > > syntax match myTag /Mon/ > syntax match myTag /Tue/ > syntax match myTag /Wed/ > > How do I make this work with just one statement ?!?!? > > > > > __________________________________________________________________________________ Find local businesses and services in your area with Yahoo!7 Local. Get started: http://local.yahoo.com.au --~--~---------~--~----~------------~-------~--~----~ You received this message from the "vim_use" maillist. For more information, visit http://www.vim.org/maillist.php -~----------~----~----~----~------~----~------~--~---
