function_reference.cpp 644 B

123456789101112131415161718192021222324
  1. // (C) Copyright Tobias Schwinger
  2. //
  3. // Use modification and distribution are subject to the boost Software License,
  4. // Version 1.0. (See http://www.boost.org/LICENSE_1_0.txt).
  5. //------------------------------------------------------------------------------
  6. #include <boost/mpl/assert.hpp>
  7. #include <boost/mpl/vector.hpp>
  8. #include <boost/type_traits/is_same.hpp>
  9. #include <boost/function_types/function_reference.hpp>
  10. namespace ft = boost::function_types;
  11. namespace mpl = boost::mpl;
  12. using boost::is_same;
  13. typedef int (& expected)(int);
  14. BOOST_MPL_ASSERT((
  15. is_same< ft::function_reference< mpl::vector<int,int> >::type, expected >
  16. ));