I am not an expert in boost, though I have used ublas extensively. Recently, my supervisor asked me to build boost regex for the gcc platform. My question is:
Why can’t I use the regex as it is, like ublas?
Please give detailed answer.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
I’m assuming that by ‘can’t use the regex as it is’ you mean ‘without having to build it seperately’.
Short answer: uBLAS is ‘header-only’ (http://www.boost.org/doc/libs?view=filtered_header-only), and Regex is not.
A ‘header-only’ library’s implementation entirely resides in header (.hpp) files. To use it, one only has to #include these headers.
A ‘non-header-only’ (‘normal’?) library has headers declaring the library’s interface, but the implementation is in .cpp files, which are built seperately and then linked into the final executable. In Boost, the .cpp files are normally in boost/libs/<library-name>/src.