jakarta-oro-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Daniel F. Savarese" <...@savarese.org>
Subject Re: Stack Overflow Problem
Date Mon, 10 Feb 2003 17:51:36 GMT

In message <3E47D9AA.4731.F738D09@localhost>, "Martin Thomas" writes:
>Actually, exactly the same occurs using:
>
>String expression = "Baseline(.)*";

Er, how long is the string you're matching against?  It really helps
if you include the exact input you're using so that others can
reproduce your problem.  I shouldn't have to spend my time constructing
arbitrarily large inputs with different permutations of strings (e.g.,
containing Baseline, not containing it, containing thousands of characters
before a newline, not, etc.).  Which, by the way, I just did.

When you don't need capturing parentheses, don't use them.  In
other words:
   Baseline(?:.)*
And when you don't need grouping, don't use it.  In other words:
   Baseline.*

As I said before, Perl regular expressions are miniature programs ...

daniel



---------------------------------------------------------------------
To unsubscribe, e-mail: oro-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: oro-user-help@jakarta.apache.org


Mime
View raw message