|
|
|
#1 |
|
Messages: n/a
Hébergeur: |
Dear fellow developers,
I am looking for a good regular expressions handling library. Am developing an application under Fedora Linux and putting "include <regex.h>" in my code does not make my compiler complain. I assume this is the library documented in http://www.opengroup.org/onlinepubs/...s/regex.h.html document. However I am wondering whether regex.h library is okay, or would you guys recommend me to use something else (Boost RegEx libraries for example?)? Cheers, Alex |
|
|
|
#2 |
|
Messages: n/a
Hébergeur: |
On 2007-12-28 13:48, alexrixhardson@yahoo.com wrote:
> Dear fellow developers, > > I am looking for a good regular expressions handling library. Am > developing an application under Fedora Linux and putting "include > <regex.h>" in my code does not make my compiler complain. I assume > this is the library documented in http://www.opengroup.org/onlinepubs/...s/regex.h.html > document. However I am wondering whether regex.h library is okay, or > would you guys recommend me to use something else (Boost RegEx > libraries for example?)? The next version of the C++ standard will include a regex library, and while I have not checked I am quite sure that it will be based on Boost RegEx, so going that way will probably ensure forward compatibility. -- Erik Wikström |
|
|
|
#3 |
|
Messages: n/a
Hébergeur: |
alexrixhard...@yahoo.com:
> Dear fellow developers, > > I am looking for a good regular expressions handling library. Am > developing an application under Fedora Linux and putting "include > <regex.h>" in my code does not make my compiler complain. I assume > this is the library documented in http://www.opengroup.org/onlinepubs/...s/regex.h.html > document. However I am wondering whether regex.h library is okay, or > would you guys recommend me to use something else (Boost RegEx > libraries for example?)? > Don't reinvent the wheel. Linux has powerful methods to allow processes to communicate effectively. Start a perl program that will parse text with perl's regular expressions, and then read its output from your C++ program. With a little effort you get your solution and bonus of parallelized and syncronized processes of parsing text (perl program) and handling parsing results (C++ program). |
|
|
|
#4 |
|
Messages: n/a
Hébergeur: |
There are two good open source regex libraries. For C++
the boost regex library is probably as good as it gets. If you want an older UNIX C-style regex Henry Spencer wrote one decades ago at University of Toronto that's still making the rounds (and a lot of other regex stuff is lifted straight from it). |
|
|
|
#5 |
|
Messages: n/a
Hébergeur: |
On 2007-12-28 07:42:27 -0600, Pavel Shved <Pavel.Shved@gmail.com> said:
> alexrixhard...@yahoo.com: >> Dear fellow developers, >> >> I am looking for a good regular expressions handling library. Am >> developing an application under Fedora Linux and putting "include >> <regex.h>" in my code does not make my compiler complain. I assume >> this is the library documented in >> http://www.opengroup.org/onlinepubs/...s/regex.h.html >> document. However I am wondering whether regex.h library is okay, or >> would you guys recommend me to use something else (Boost RegEx >> libraries for example?)? >> > > Don't reinvent the wheel. Linux has powerful methods to allow > processes to communicate effectively. Start a perl program that will > parse text with perl's regular expressions, and then read its output > from your C++ program. With a little effort you get your solution and > bonus of parallelized and syncronized processes of parsing text (perl > program) and handling parsing results (C++ program). I don't see how using an existing library is reinventing the wheel. -dr |
|
![]() |
| Outils de la discussion | |
|
|