In article <[EMAIL PROTECTED]>,
[EMAIL PROTECTED] (Dan Anderson) writes:
>
> I was reading O'Reilly's Programming Perl, and under the
>security section it says that regular expressions from outside the
>program are not trusted because it is possible that they can take
>forever to execute.
>
> I was curious exactly what kind of regular expression takes
>forever to execute? Are these common, and is it possible that I can
>accidentally take forever to use a regular expression? Can anyone
>provide me with more information then O'Reilly's "some regular
>expressions take an exponential time to execute"?
Personally, I've never constructed one by accident. They involve
nested quantifiers in certain situations. You can see a bit of
discussion on a case at
http://perl.plover.com/yak/regex/samples/slide065.html
which should be enough to explain it for you.
--
Peter Scott
http://www.perldebugged.com/
*** NEW *** http//www.perlmedic.com/
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>