No such thing as a small change | |
PerlMonks |
Re^2: regexp - repeatedly delete words expressed in alternation from end of stringby princepawn (Parson) |
on Nov 06, 2007 at 18:10 UTC ( [id://649298]=note: print w/replies, xml ) | Need Help?? |
Note: You were using capturing parens ((...)) when you only needed non-capturing parens ((?:...)). Removing the need to capture greatly improves the speed of regexs.Thanks for this. Thing is, I have an entire module full of this mistake. Unless there is a pragma to fix this, then I have to go fix them all manually.
Ivan Raikov says: the first step to understanding recursion is to begin by understanding recursion.
In Section
Seekers of Perl Wisdom
|
|