I'm trying to use and_ in my code, and I'm having an issue with it's return type. I'm trying to use it with other metaprogramming constructs that accept and return true_type or false_type, and I use SFINAE overloads with those types also. boost::mpl::and_ and boost::mpl::or_ return different types from much of the rest of the mpl. At least, it appears this way to me.
mpl_::failed************ boost::is_same<mpl_::bool_<true>, boost::integral_constant<bool, true> >::************)
So, how do I write the following so that it passes the assert?
template <typename T, typename U>
void foo(const T& test, const U& test2)
{
typedef typename boost::mpl::and_<typename utilities::is_vector<T>, typename utilities::is_vector<U> >::type asdf;
BOOST_MPL_ASSERT(( boost::is_same<asdf, boost::true_type::value> ));
}
void fooer()
{
std::vector<int> test1;
std::vector<int> test2;
foo(test1, test2);
}