my $re = qr/(?:match|matching\.com|match.company)/i; print "regexp - $re"; __output__ regexp - (?i-xsm:(?:match|matching\.com|match.company)) #### my $re = qr/(match|matching\.com|match.company)/i; print "old - $1\n" if "matching.com" =~ $re; $re = qr/(matching\.com|match.company|match)/i; print "new - $1\n" if "matching.com" =~ $re; __output__ old - match new - matching.com