Regular expressions are not part of the C++ standard library or STL though there is a Boost regular expression library and there is regex.h written by Henry Spencer for the GNU GCC compiler. I'm not sure if that works with Watcom or Microsoft compilers but I'll see if I can get it to work.
If you use Microsoft Visual C++ 6.0 or 7 then you can use Greta. It's a free library from Microsoft Research that provides Perl 5 compatible regular expressions; a complicated but very powerful method of pattern matching that looks at first glance pretty incomprehensible. E.g.
I haven't written any regex in years and am busy refreshing my memory of them. Once I've done that I'll show you how to use them.
- You'll find a link to Greta in the C++ Code Library