develooper Front page | perl.perl5.porters | Postings from December 2014

Re: All I want for Christmas is: Streaming Regexps

Thread Previous
From:
hv
Date:
December 25, 2014 15:41
Subject:
Re: All I want for Christmas is: Streaming Regexps
Message ID:
201412251411.sBPEBGu17955@crypt.org
"Paul \"LeoNerd\" Evans" <leonerd@leonerd.org.uk> wrote:
:In summary:
:
:  I'd like a way to know if a regexp fails to match because it ran out
:  of input but was happy until that point, or if it found some bad
:  characters that adding more input to will never help.

I'd also love to have this, but to get it you need to be able to turn off
any optimizations that make it impossible to know, such as "string too
short".

Which I think means that first we need a way to make it possible to turn
optimizations on and off individually - which is something we're working
towards already - and then we need to understand which of them would need
to be turned off in this case.

(I suspect once you have control of the individual optimizations, you
might even be able to do the rest in a module, by injecting an appropriate
assertion.)

Hugo

Thread Previous


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About