On Tue, Sep 05, 2006 at 06:51:57PM +1000, Peter Hodge wrote:
> Hello all,
>
> Given the following text:
>
> inte
> integ
> intege
> integer
> inter
> interv
> interva
> interval
>
> is there any easy way to make these two commands work?
>
> syntax match Error /int\%[eger]/
> syntax match Error /int\%[erval]/
>
> The second match begins taking priority as soon as the word is 'inte', and
> prevents 'integer' from being matched correctly.
>
> regards,
> Peter
How about adding end-of-word patterns:
syntax match Error /int\%[eger]\>/
syntax match Error /int\%[erval]\>/
HTH --Benji Fisher