PR79156 fix std::__enable_shared_from_this extension
authorJonathan Wakely <jwakely@redhat.com>
Fri, 20 Jan 2017 00:07:14 +0000 (00:07 +0000)
committerJonathan Wakely <redi@gcc.gnu.org>
Fri, 20 Jan 2017 00:07:14 +0000 (00:07 +0000)
commit115ac9ff61a51bca1ad98dff8192c23e685249ea
treedb28cb937eb52ed6ae3d5ad02debde519bd856cf
parent27169e45d4c16032c2fdee7b89883a1ca62b2b93
PR79156 fix std::__enable_shared_from_this extension

PR libstdc++/79156
* include/bits/shared_ptr_base.h (__enable_shared_from_this_base):
Fix return type.
(__enable_shared_from_this): Declare __shared_ptr as a friend.
* testsuite/ext/shared_ptr/1.cc: New test.

From-SVN: r244668
libstdc++-v3/ChangeLog
libstdc++-v3/include/bits/shared_ptr_base.h
libstdc++-v3/testsuite/ext/shared_ptr/1.cc [new file with mode: 0644]