in reply to Negation/Complement of a Regex

Instead of passing around regexes, pass around matching subroutines. Then you can do:

my $match = sub { $_[0] =~ /.../ }; my $negated = sub { not $match->(@_) };

Now that's some Higher Order Perl I can live with!

-sam