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:
>>
>> https://github.com/boostorg/program_options/commit/0f9793e369d0068fb65f812907c166c71fa5f2e4
>>
>
> 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 boost.org 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
http://vladimirprus.com

Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net