[libstdc++ PATCH] Implement observer_ptr

Jonathan Wakely jwakely@redhat.com
Sat May 2 13:01:00 GMT 2015


On 02/05/15 08:49 -0400, Ed Smith-Rowland wrote:
>OK.  Thanks.
>
>I do remember an SD-6 discussion about how annoying the 
>define-the-macro-in-all-relevant-headers was.
>I didn't know there was a resolution.  I need to reeducate myself.
>Meanwhile I'll rollback my patch.
>
>Reverted in 222722.
>
>I'll ask next time.
>Sorry for the noise.

OK, no problem. I wasn't going to ask you to revert it, as it didn't
really do any harm, I just don't think it is required to be in every
header.

I've been wondering if it would be better to just put all the
feature-test macros in a central place, like <bits/c++config.h> (and
maybe somewhre separate for the "experimental" ones). Stephen Kelly's
complaints about Boost having to include loads of large std::lib
headers to test the macros is a valid complaint about the current SD-6
scheme.

I *think* that would also still be conforming, because the macro would
be defined when you include the right header ... it would just be
defined when you include any other headers too :-)



More information about the Libstdc++ mailing list