in reply to look behind in REs
$line =~ s/BA/XXXXsome magic sequenceXXXX/g; $line =~ s/A/Z/g; $line =~ s/XXXXsome magic sequenceXXXX/BA/g; [download]