A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2003-February/033743.html below:

[Python-Dev] Re: re recursion limit

[Python-Dev] Re: re recursion limitA.M. Kuchling amk@amk.ca
Wed, 26 Feb 2003 17:19:51 -0500
Gary Herron wrote:
 >I wrote:
>>Maybe just fixing the problem for .* will be sufficient.

Sorry, brain error on my part: I meant fixing it for .*?.
.* doesn't have a problem because the engine can chew up as many matches 
for '.' as possible, try the rest of the pattern, and then back up
for '.'.

In other words: .* requires stack space proportional to the size of the 
regex pattern, which is OK; .*?, as currently implemented, requires
stack space proportional to the size of *the string being matched*, 
which is what causes the problem.

--amk                                                    (www.amk.ca)
MIRANDA: Your tale, sir, would cure deafness.
       -- _The Tempest_, I, ii





RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4