consider the following code:
perl -wne 'chomp;print if m/[^(?:test)]/'
I was surprised to see that grouping inside a character class works. How is this different from (?!pattern) ?
(?!pattern)
/[^(?:test)]/
not grouped in char class. All char listed in [] after ^ will be processed literally, and this will match any string containing char except ( ? : t e s t )
(
?
:
t
e
s
)