in reply to Problem with negative lookahead at end of string

Despite a processing slowdown, I prefer the readability of splitting criteria like this up into multiple expressions:

/^chars/ && /this/ && !/that/ && !/whatever$/

Replies are listed 'Best First'.
Re^2: Problem with negative lookahead at end of string
by runrig (Abbot) on Jun 21, 2004 at 17:40 UTC
    Despite a processing slowdown...

    It depends on the patterns and the string, but it's often faster (and in this case it is faster) to split up the matches into multiple regexes.