[pcre-dev] [Bug 1437] Using PCRE-8.34 on x86-64 Linux with …

Pàgina inicial
Delete this message
Autor: Philip Hazel
Data:  
A: pcre-dev
Assumpte: [pcre-dev] [Bug 1437] Using PCRE-8.34 on x86-64 Linux with --enable-jit and --enable-utf , grep -iP '^S' gets stuck on a binary file consuming a lot of CPU for many seconds
------- You are receiving this mail because: -------
You are on the CC list for the bug.

http://bugs.exim.org/show_bug.cgi?id=1437




--- Comment #11 from Philip Hazel <ph10@???> 2014-01-24 16:48:06 ---
On Fri, 24 Jan 2014, Ze'ev Atlas wrote:

> Why is that so hard to enforce '^' to start where it supposed to be
> (i.e. in the absolute start of the supplied string)?


I think you misunderstand '^'.

1. It need not be at the start of the regex: /abc|^xyz/ for example
(this is a perfectly reasonable pattern you might give to grep for "find
a line containing 'abc' or beginning with 'xyz'".)

2. It does not always match at the start of the subject string: in
multiline mode it can match after a newline in the middle of a string.

Philip


--
Configure bugmail: http://bugs.exim.org/userprefs.cgi?tab=email