]> git.proxmox.com Git - ceph.git/blobdiff - ceph/src/boost/libs/mp11/test/mp_defer.cpp
update sources to ceph Nautilus 14.2.1
[ceph.git] / ceph / src / boost / libs / mp11 / test / mp_defer.cpp
index 75f3128cb3ee3ede23343f33dc3d6f2c8c4dba9c..a21323da21b2671ba410b98f6c0160cb41f1f7c8 100644 (file)
@@ -31,6 +31,11 @@ using boost::mp11::mp_defer;
 template<class T> using add_pointer = T*;
 template<class... T> using add_pointer_impl = mp_defer<add_pointer, T...>;
 
+using boost::mp11::mp_quote;
+
+using Q_add_pointer = mp_quote<add_pointer>;
+template<class... T> using Q_add_pointer_impl = mp_defer<Q_add_pointer::fn, T...>;
+
 int main()
 {
     BOOST_TEST_TRAIT_TRUE((has_type<add_pointer_impl<void>>));
@@ -42,5 +47,18 @@ int main()
     BOOST_TEST_TRAIT_FALSE((has_type<add_pointer_impl<>>));
     BOOST_TEST_TRAIT_FALSE((has_type<add_pointer_impl<void, void>>));
 
+#if !BOOST_WORKAROUND( BOOST_MSVC, <= 1800 )
+    BOOST_TEST_TRAIT_TRUE((has_type<Q_add_pointer_impl<void>>));
+#endif
+    BOOST_TEST_TRAIT_TRUE((std::is_same<Q_add_pointer_impl<void>::type, void*>));
+
+#if !BOOST_WORKAROUND( BOOST_MSVC, <= 1800 )
+    BOOST_TEST_TRAIT_TRUE((has_type<Q_add_pointer_impl<int>>));
+#endif
+    BOOST_TEST_TRAIT_TRUE((std::is_same<Q_add_pointer_impl<int>::type, int*>));
+
+    BOOST_TEST_TRAIT_FALSE((has_type<Q_add_pointer_impl<>>));
+    BOOST_TEST_TRAIT_FALSE((has_type<Q_add_pointer_impl<void, void>>));
+
     return boost::report_errors();
 }