[PATCH] Define feature-test macro for std::enable_shared_from_this
Jonathan Wakely
jwakely@redhat.com
Thu Aug 4 12:33:00 GMT 2016
On 03/08/16 20:11 +0100, Jonathan Wakely wrote:
>Another feature we already support, so just define the macro.
>
> * include/bits/shared_ptr_base.h (__cpp_lib_enable_shared_from_this):
> Define feature-test macro.
> * testsuite/20_util/enable_shared_from_this/members/reinit.cc: Test
> for the macro.
>
>Tested x86_64-linux, committed to trunk.
I realised we don't actually implement the whole feature, because we
don't have the new weak_from_this() members (careless of me to forget
the contents of my own proposal!)
This adds them for C++17, or gnu++1*, and only defines the
feature-test macro when those members are present.
Tested powerpc64-linux, committed to trunk.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch.txt
Type: text/x-patch
Size: 2904 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/libstdc++/attachments/20160804/2b92a54d/attachment.bin>
More information about the Libstdc++
mailing list