Boost logo

Boost Users :

Subject: Re: [Boost-users] [program options] option_groups.cpp example doesn't compile
From: Vladimir Prus (vladimir_at_[hidden])
Date: 2015-02-15 23:38:57

On 02/16/2015 01:53 AM, U.Mutlu wrote:
> Vladimir Prus wrote, On 02/15/2015 07:43 PM:
>> On 02/15/2015 09:03 PM, U.Mutlu wrote:
>>> I've boost 1.55 from the debian repository.
>>> I'm trying to compile the below example of the 1.55 version
>>> (it's same as that of 1.57), but I get the following compile errors.
>>> Should I use some 'magic' compiler options, or what else is the reason for
>>> this grandious failure?
>>> $ g++ -Wall -std=gnu++11 option_groups.cpp -lboost_program_options
>>> option_groups.cpp: In function ‘int main(int, char**)’:
>>> option_groups.cpp:44:46: error: ‘class
>>> boost::program_options::typed_value<std::basic_string<char>, char>’ has no
>>> member named ‘implicit’
>>> ("help-module", value<string>()->implicit(),
>>> ^
>>> option_groups.cpp:96:11: error: reference to ‘exception’ is ambiguous
>>> catch(exception& e) {
>> Fixed here:
> Ok, thx, now with these changes it compiles successfully.
> BTW, as said in other posting of mine today, in the online-documentation
> of this sub-library at a link to its "example" directory is missing.

Could you be more specific as to what page contains a broken link or fails to contain a link?

It's a bit hard to produce an absolute link that will work for official release, for Ubuntu
package and for website, all at the same time.

Vladimir Prus
CodeSourcery / Mentor Embedded

Boost-users list run by williamkempf at, kalb at, bjorn.karlsson at, gregod at, wekempf at