Ticket #6755: result_of.patch
File result_of.patch, 2.0 KB (added by , 11 years ago) |
---|
-
boost/utility/detail/result_of_iterate.hpp
40 40 BOOST_PP_ENUM_PARAMS(BOOST_PP_ITERATION(),typename T)> 41 41 struct result_of<F(BOOST_PP_ENUM_PARAMS(BOOST_PP_ITERATION(),T))> 42 42 : mpl::if_< 43 mpl::or_< is_pointer<F>, is_member_function_pointer<F>>43 is_member_function_pointer<F> 44 44 , detail::tr1_result_of_impl< 45 45 typename remove_cv<F>::type, 46 46 typename remove_cv<F>::type(BOOST_PP_ENUM_PARAMS(BOOST_PP_ITERATION(),T)), false -
libs/utility/test/result_of_test.cpp
193 193 BOOST_STATIC_ASSERT((is_same<result_of<mem_func_ptr_v(X,char)>::type, int>::value)); 194 194 BOOST_STATIC_ASSERT((is_same<result_of<mem_func_ptr_cv(X,char)>::type, int>::value)); 195 195 BOOST_STATIC_ASSERT((is_same<result_of<mem_func_ptr_0(X)>::type, int>::value)); 196 BOOST_STATIC_ASSERT((is_same<result_of<func_ptr(void)>::type, int>::value));197 196 198 197 BOOST_STATIC_ASSERT((is_same<tr1_result_of<func_ptr(char, float)>::type, int>::value)); 199 198 BOOST_STATIC_ASSERT((is_same<tr1_result_of<func_ref(char, float)>::type, int>::value)); … … 205 204 BOOST_STATIC_ASSERT((is_same<tr1_result_of<mem_func_ptr_cv(X,char)>::type, int>::value)); 206 205 BOOST_STATIC_ASSERT((is_same<tr1_result_of<mem_func_ptr_0(X)>::type, int>::value)); 207 206 BOOST_STATIC_ASSERT((is_same<tr1_result_of<func_ptr(void)>::type, int>::value)); 207 BOOST_STATIC_ASSERT((is_same<tr1_result_of<func_ref(void)>::type, int>::value)); 208 208 209 209 BOOST_STATIC_ASSERT((is_same<result_of<result_of_member_function_template(double)>::type, double>::value)); 210 210 BOOST_STATIC_ASSERT((is_same<result_of<const result_of_member_function_template(double)>::type, const double>::value));