diff --git a/test/Jamfile b/test/Jamfile index 048691f2..e8d17be0 100644 --- a/test/Jamfile +++ b/test/Jamfile @@ -9,6 +9,7 @@ #============================================================================== # bring in rules for testing import testing ; +import ../../config/checks/config : requires ; project : requirements @@ -71,7 +72,8 @@ project [ run sequence/convert_deque.cpp ] [ run sequence/convert_list.cpp ] [ run sequence/convert_std_pair.cpp ] - [ run sequence/convert_std_tuple.cpp ] + [ run sequence/convert_std_tuple.cpp : : + : [ requires cxx11_variadic_templates cxx11_hdr_tuple ] ] [ run sequence/convert_vector.cpp ] [ run sequence/filter_view.cpp ] [ run sequence/hash.cpp ] @@ -123,7 +125,8 @@ project [ run sequence/std_pair.cpp ] [ run sequence/boost_array.cpp ] [ run sequence/array.cpp ] - [ run sequence/std_array.cpp ] + [ run sequence/std_array.cpp : : + : [ requires cxx11_hdr_array ] ] [ run sequence/tuple_comparison.cpp ] [ run sequence/tuple_construction.cpp ] [ run sequence/tuple_conversion.cpp ] @@ -210,8 +213,10 @@ project [ run sequence/define_assoc_tpl_struct.cpp ] [ run sequence/define_assoc_tpl_struct_empty.cpp ] [ run sequence/define_assoc_tpl_struct_move.cpp ] - [ run sequence/std_tuple.cpp ] - [ run sequence/std_tuple_iterator.cpp ] + [ run sequence/std_tuple.cpp : : + : [ requires cxx11_variadic_templates cxx11_hdr_tuple ] ] + [ run sequence/std_tuple_iterator.cpp : : + : [ requires cxx11_variadic_templates cxx11_hdr_tuple ] ] [ run sequence/ref_vector.cpp ] [ run sequence/flatten_view.cpp ] diff --git a/test/sequence/convert_std_tuple.cpp b/test/sequence/convert_std_tuple.cpp index 3e28276c..643f01cf 100644 --- a/test/sequence/convert_std_tuple.cpp +++ b/test/sequence/convert_std_tuple.cpp @@ -8,18 +8,13 @@ #include -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) +#if defined(BOOST_NO_CXX11_HDR_TUPLE) || \ + defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) +# error "does not meet requirements" +#endif #include #include #define FUSION_SEQUENCE std::tuple #include "convert.hpp" - -#else - -int main() -{ -} - -#endif diff --git a/test/sequence/std_array.cpp b/test/sequence/std_array.cpp index fdf761bf..902cbeca 100644 --- a/test/sequence/std_array.cpp +++ b/test/sequence/std_array.cpp @@ -6,9 +6,10 @@ // at http://www.boost.org/LICENSE_1_0.txt) // #include + #ifdef BOOST_NO_CXX11_HDR_ARRAY -int main() {} -#else +# error "does not meet requirements" +#endif #ifdef BOOST_MSVC #pragma warning(disable:4180) @@ -46,4 +47,3 @@ int main() return boost::report_errors(); } -#endif diff --git a/test/sequence/std_tuple.cpp b/test/sequence/std_tuple.cpp index 257fd850..3d711071 100644 --- a/test/sequence/std_tuple.cpp +++ b/test/sequence/std_tuple.cpp @@ -8,8 +8,10 @@ #include // adapted/std_tuple.hpp only supports implementations using variadic templates -#if !defined(BOOST_NO_CXX11_HDR_TUPLE) && \ - !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) +#if defined(BOOST_NO_CXX11_HDR_TUPLE) || \ + defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) +# error "does not meet requirements" +#endif #include #include @@ -19,8 +21,7 @@ #include #include -int -main() +int main() { using namespace boost::fusion; using namespace boost; @@ -34,13 +35,3 @@ main() return boost::report_errors(); } - -#else - -int -main() -{ - return 0; -} - -#endif diff --git a/test/sequence/std_tuple_iterator.cpp b/test/sequence/std_tuple_iterator.cpp index e33db386..df283331 100644 --- a/test/sequence/std_tuple_iterator.cpp +++ b/test/sequence/std_tuple_iterator.cpp @@ -8,8 +8,10 @@ // The std_tuple_iterator adaptor only supports implementations // using variadic templates -#if !defined(BOOST_NO_CXX11_HDR_TUPLE) && \ - !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) +#if defined(BOOST_NO_CXX11_HDR_TUPLE) || \ + defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) +# error "does not meet requirements" +#endif #include @@ -17,20 +19,8 @@ #define FUSION_TRAVERSAL_TAG random_access_traversal_tag #include "./iterator.hpp" -int -main() +int main() { test(); return boost::report_errors(); } - -#else - -int -main() -{ - return 0; -} - -#endif -