On Jan 5, 12:13 am, moonb...@gmail.com (Erez Schatz) wrote:
> 2010/1/5 Jeff Peng <jeffp...@netzero.net>:
>
> ...
> This is something that Perl  (post version 5.6) does inherently, which
> is compiling a regex only once as long as the pattern isn't modified.
> Prior to 5.6 you'd need to use the /o modifier (
> m/href="http:\/\/(.*?)\/.*" target="_blank"/o ).
>

Um no.  The /o modifer stops re-compilation only if the regex
needs to interpolate a variable. Otherwise, /o has no effect.
Perl, has always AFAIK, cached regex compilations for re-use
if there aren't variable interpolations since then the regex
can't possibly change.

--
Charles DeRykus





--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/


Reply via email to