bug-gawk
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [bug-gawk] Efficient regex library which I can use in my C++ code?


From: Alec Taylor
Subject: Re: [bug-gawk] Efficient regex library which I can use in my C++ code?
Date: Tue, 1 Nov 2011 12:20:07 +1100

Great, thanks for the info

On Tue, Nov 1, 2011 at 5:38 AM, Aharon Robbins <address@hidden> wrote:
> Hi. Re this:
>
>> Date: Fri, 28 Oct 2011 01:46:20 +1100
>> From: Alec Taylor <address@hidden>
>> To: address@hidden
>> Subject: [bug-gawk] Efficient regex library which I can use in my C++ code?
>>
>> Good afternoon,
>>
>> I am looking for the most efficient open-source C++ regex library.
>>
>> Reading this article: http://swtch.com/~rsc/regexp/regexp1.html - It
>> seems that GNU awk is the best overall:
>> http://pdos.csail.mit.edu/~rsc/regexp-img/grep1p.png
>>
>> Can you recommend an embeddable C++ library which offers the same or
>> better efficient of gawk, with a similar permissive open-source
>> license?
>>
>> Thanks for all information,
>>
>> Alec Taylor
>
> At the http://swtch.com/~rsc/regexp/ page are links to several regexp
> libraries, including the one that Russ Cox wrote in C++
> (http://code.google.com/p/re2/).
>
> Qt also has regular expression matching facilities, if I recall correctly.
>
> Gawk gets its speed by cheating. It uses the fast DFA matcher from
> GNU grep for "does it match?" cases, and falls back to the full regex
> matcher from GLIBC for "where does it match?" cases.
>
> Both matchers are written in C and require you to understand the gosh-awful
> syntax bits in order to use them.  There is no C++ wrapper for either of
> them that I know about, although it would not be hard to write one to wrap
> one, the other, or both.
>
> Hope this helps,
>
> Arnold
>



reply via email to

[Prev in Thread] Current Thread [Next in Thread]