I might be responsible for that optimization. I made some modifications to the regex engine a couple years ago involving skipping non-pattern parts of regexes when looking to optimize. So, how can can you defeat it? Well, you could wrap the 'XXX' inside a (??{ ... }).
Jeff japhy Pinyan,
P.L., P.M., P.O.D, X.S.:
Perl,
regex,
and perlhacker How can we ever be the sold short or the cheated, we who for every service have long ago been overpaid? ~~ Meister Eckhart