Solved

How to use regular expressions in C++ for Linux environment.

Posted on 2011-03-17
3
381 Views
Last Modified: 2012-05-11

Dear experts,

I want to implement regular expressions in C++ for Linux environment. One of my friend recommended me to use REGEX Library by GNU. Could you provide me some documentation as well as code examples about using this library?

BR,
0
Comment
Question by:GurcanK
3 Comments
 
LVL 40

Accepted Solution

by:
evilrix earned 125 total points
ID: 35155699
I'd strongly recommend you consider using the regex library that is part of boost. Not only is it a fantastic library it will end up being part of the next version of the CPP standard.

http://www.boost.org/doc/libs/1_46_1/libs/regex/doc/html/index.html
http://en.wikipedia.org/wiki/C%2B%2B0x#Regular_expressions
0
 
LVL 33

Assisted Solution

by:sarabande
sarabande earned 125 total points
ID: 35155825
for C development simply do 'man regex' at the shell and you see the syntax for reccomp (compiles a regular expression) and regexec (applies the regular expression). i used it once and had no significant problems.

Sara

0
 
LVL 11

Expert Comment

by:DeepuAbrahamK
ID: 35156232
0

Featured Post

Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Have you thought about creating an iPhone application (app), but didn't even know where to get started? Here's how: ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ Important pre-programming comments: I’ve never tri…
An Outlet in Cocoa is a persistent reference to a GUI control; it connects a property (a variable) to a control.  For example, it is common to create an Outlet for the text field GUI control and change the text that appears in this field via that Ou…
The goal of this video is to provide viewers with basic examples to understand recursion in the C programming language.
The goal of this video is to provide viewers with basic examples to understand how to create, access, and change arrays in the C programming language.

821 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question