in reply to positive regex for inverted match

This is discussed at length in the Perl Cookbook, 2nd edition, recipe 6.18.

As to why, it is common for a program to accept a pattern as one of its arguments; in that case you cannot use $_ !~ /bar/ but must instead resort to:

/^(?:(?!bar).)*$/s