From 65c8c63ddb7f6b1e4eb0440c3bbba1ab335cea34 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ion=20Gazta=C3=B1aga?= Date: Thu, 4 Sep 2014 00:24:44 +0200 Subject: [PATCH] Fixed is_convertible bug in missing_virtual_destructor --- .../boost/move/detail/unique_ptr_meta_utils.hpp | 15 ++++----------- 1 file changed, 4 insertions(+), 11 deletions(-) diff --git a/include/boost/move/detail/unique_ptr_meta_utils.hpp b/include/boost/move/detail/unique_ptr_meta_utils.hpp index 89143a7..42fd272 100644 --- a/include/boost/move/detail/unique_ptr_meta_utils.hpp +++ b/include/boost/move/detail/unique_ptr_meta_utils.hpp @@ -556,28 +556,21 @@ struct is_unary_function ////////////////////////////////////// template< class T, class U - , bool enable = is_convertible< typename remove_cv::type* - , typename remove_cv::type*>::value && + , bool enable = is_convertible< U*, T*>::value && !is_array::value && !is_same::type, void>::value && !is_same::type, typename remove_cv::type>::value > struct missing_virtual_destructor_default_delete -{ - static const bool value = !has_virtual_destructor::value; -}; +{ static const bool value = !has_virtual_destructor::value; }; template struct missing_virtual_destructor_default_delete -{ - static const bool value = false; -}; +{ static const bool value = false; }; template struct missing_virtual_destructor -{ - static const bool value = false; -}; +{ static const bool value = false; }; template struct missing_virtual_destructor< ::boost::movelib::default_delete, U >