summaryrefslogtreecommitdiffstats
path: root/libcxx/include
diff options
context:
space:
mode:
Diffstat (limited to 'libcxx/include')
-rw-r--r--libcxx/include/memory5
1 files changed, 3 insertions, 2 deletions
diff --git a/libcxx/include/memory b/libcxx/include/memory
index 588b3ce10b4..2a25f0ecb50 100644
--- a/libcxx/include/memory
+++ b/libcxx/include/memory
@@ -4713,7 +4713,7 @@ inline _LIBCPP_INLINE_VISIBILITY
typename enable_if
<
!is_array<_Yp>::value &&
- is_convertible<_Yp*, element_type*>::value,
+ is_convertible<_Yp*, typename shared_ptr<_Tp>::element_type*>::value,
shared_ptr<_Tp>&
>::type
shared_ptr<_Tp>::operator=(auto_ptr<_Yp> __r)
@@ -4728,7 +4728,8 @@ inline _LIBCPP_INLINE_VISIBILITY
typename enable_if
<
!is_array<_Yp>::value &&
- is_convertible<typename unique_ptr<_Yp, _Dp>::pointer, element_type*>::value,
+ is_convertible<typename unique_ptr<_Yp, _Dp>::pointer,
+ typename shared_ptr<_Tp>::element_type*>::value,
shared_ptr<_Tp>&
>::type
shared_ptr<_Tp>::operator=(unique_ptr<_Yp, _Dp> __r)
OpenPOWER on IntegriCloud