Boost logo

Boost :

Subject: Re: [boost] Curiousity question
From: Edward Diener (eldiener_at_[hidden])
Date: 2016-10-13 11:59:54


On 10/13/2016 10:56 AM, Andrey Semashev wrote:
> On 10/13/16 17:33, Edward Diener wrote:
>> On 10/13/2016 10:00 AM, Andrey Semashev wrote:
>>>
>>> There is always a list of supported targets. If that list includes a
>>> target without C++11 then I'll probably use boost::shared_ptr. That is
>>> what I'm doing in Boost.Log, which supports C++03.
>>
>> I understand that and I think that is the general consensus. But what
>> might happen, not that it seems to bother anyone much but me <g>, is
>> that your library, which supports C++03, is nevertheless "compiled" by
>> some programmer(s) using C++11 in their own project. Then their normal
>> use of std::shared_ptr ( because it's there and naturally supported by
>> their compiler implementation in C++11 mode ) doesn't really "play well"
>> with your own use of boost::shared_ptr. Of course you may well say
>> "what's the big deal, when you interface with my library you will use
>> boost::shared_ptr and have a dependency on it, while otherwise you have
>> chosen to use std::shared_ptr and have a dependency on your compiler's
>> implementation. I see no problem with that." And technically you would
>> be right, but practically the user of your library might feel
>> differently about it.
>
> Well, that's a nuisance for the user, no doubt. But that's the
> consequence of the chosen balance between my burden as the library
> maintainer and user's convenience. Having configurable library interface
> can be a headache of itself, it doesn't look like a clear cut solution.

It is certainly easier just to make a choice and stay with it. I don't
think that cxx_dual is a "headache" but of course I am biased, being the
author. But it is good to know where you stand on this. Thanks !


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk