Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: [BUG] Long line makes pattern matching (by //) hog Zsh



On 5 June 2016 at 22:39, Peter Stephenson <p.w.stephenson@xxxxxxxxxxxx> wrote:
> We are maybe being naive in treating [...] expressions as if they are
> "simple".  I think we have better protection against pathological
> backtracking for more complicated patterns.
>
> Does the following help?

It's slower with this patch:

3,02s user 0,02s system 99% cpu 3,064 total
vs
1,55s user 0,24s system 93% cpu 1,909 total

for pattern with first segment removed, i.e.: ([^0-9/\\\\ ]##[^/\\\\]#(#e))

Best regards,
Sebastian Gniazdowski



Messages sorted by: Reverse Date, Date, Thread, Author