From 4c8d36d0718b903f6f3e929d4a471670317df8dc Mon Sep 17 00:00:00 2001 From: Peter Dimov Date: Thu, 21 Dec 2017 21:35:39 +0200 Subject: [PATCH] Add a few more mp_defer tests --- test/mp_defer.cpp | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/test/mp_defer.cpp b/test/mp_defer.cpp index 75f3128..a21323d 100644 --- a/test/mp_defer.cpp +++ b/test/mp_defer.cpp @@ -31,6 +31,11 @@ using boost::mp11::mp_defer; template using add_pointer = T*; template using add_pointer_impl = mp_defer; +using boost::mp11::mp_quote; + +using Q_add_pointer = mp_quote; +template using Q_add_pointer_impl = mp_defer; + int main() { BOOST_TEST_TRAIT_TRUE((has_type>)); @@ -42,5 +47,18 @@ int main() BOOST_TEST_TRAIT_FALSE((has_type>)); BOOST_TEST_TRAIT_FALSE((has_type>)); +#if !BOOST_WORKAROUND( BOOST_MSVC, <= 1800 ) + BOOST_TEST_TRAIT_TRUE((has_type>)); +#endif + BOOST_TEST_TRAIT_TRUE((std::is_same::type, void*>)); + +#if !BOOST_WORKAROUND( BOOST_MSVC, <= 1800 ) + BOOST_TEST_TRAIT_TRUE((has_type>)); +#endif + BOOST_TEST_TRAIT_TRUE((std::is_same::type, int*>)); + + BOOST_TEST_TRAIT_FALSE((has_type>)); + BOOST_TEST_TRAIT_FALSE((has_type>)); + return boost::report_errors(); }