sl@0: // Boost result_of library sl@0: sl@0: // Copyright Douglas Gregor 2004. Use, modification and sl@0: // distribution is subject to the Boost Software License, Version sl@0: // 1.0. (See accompanying file LICENSE_1_0.txt or copy at sl@0: // http://www.boost.org/LICENSE_1_0.txt) sl@0: sl@0: // For more information, see http://www.boost.org/libs/utility sl@0: #ifndef BOOST_RESULT_OF_HPP sl@0: #define BOOST_RESULT_OF_HPP sl@0: sl@0: #include sl@0: #include sl@0: #include sl@0: #include sl@0: #include sl@0: #include sl@0: sl@0: #ifndef BOOST_RESULT_OF_NUM_ARGS sl@0: # define BOOST_RESULT_OF_NUM_ARGS 10 sl@0: #endif sl@0: sl@0: namespace boost { sl@0: sl@0: template struct result_of; sl@0: sl@0: #if !defined(BOOST_NO_SFINAE) && !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) sl@0: namespace detail { sl@0: sl@0: BOOST_MPL_HAS_XXX_TRAIT_DEF(result_type) sl@0: sl@0: template struct get_result_of; sl@0: sl@0: template sl@0: struct get_result_of sl@0: { sl@0: typedef typename F::result_type type; sl@0: }; sl@0: sl@0: template sl@0: struct get_result_of sl@0: { sl@0: typedef typename F::template result::type type; sl@0: }; sl@0: sl@0: template sl@0: struct get_result_of sl@0: { sl@0: typedef void type; sl@0: }; sl@0: sl@0: template sl@0: struct result_of : get_result_of::value)> {}; sl@0: sl@0: } // end namespace detail sl@0: sl@0: #define BOOST_PP_ITERATION_PARAMS_1 (3,(0,BOOST_RESULT_OF_NUM_ARGS,)) sl@0: #include BOOST_PP_ITERATE() sl@0: sl@0: #else sl@0: # define BOOST_NO_RESULT_OF 1 sl@0: #endif sl@0: sl@0: } sl@0: sl@0: #endif // BOOST_RESULT_OF_HPP