--- Nikolai Weibull <[EMAIL PROTECTED]> wrote:
> On 10/25/06, Peter Hodge <[EMAIL PROTECTED]> wrote:
>
> > --- Nikolai Weibull <[EMAIL PROTECTED]> wrote:
>
> > > I figured that it was easier to add items to a cluster using
> > > containedin= for a syntax definition I'm writing, but it seems that
> > > one can't do it that way. Is there a reason for this, or is it an
> > > oversight? Can we add this to the todo? I've never needed it before,
> > > but for this particular grammar, it made a lot of sense.
>
> > Using 'syn keyword SomeKeyword foo [EMAIL PROTECTED]' does not add
> SomeKeyword to the cluster @SomeCluster, rather, it allows SomeKeyword be
> contained in all the items in @SomeCluster.
>
> Ah, of course. How silly of me. Although, it would be nice if this
> could be done somehow. A pair of @'s, perhaps, e.g., syn match
> Something containedin=@@Cluster '...'?
Probably better if it was '[EMAIL PROTECTED]' rather than complicating the
containedin option. If you are in the habit of spanning syntax commands across
multiple lines, then it's pretty easy to make a new line to add the item to the
cluster. I.e., if you have:
syn match foo /foo/ contained
\ [EMAIL PROTECTED]
then it could be
syn match foo /foo/ contained
syn cluster myCluster add=foo
It's not so painful.
cheers,
Peter
____________________________________________________
On Yahoo!7
Win VIP tickets to meet R'n'B stars superstars Ne-Yo and Rihanna
http://advision.webevents.yahoo.com/aunz/music/jay_z_promotion/index.htm