diff --git a/sprout/config/suffix.hpp b/sprout/config/suffix.hpp index 630e5779..d1ed8f64 100644 --- a/sprout/config/suffix.hpp +++ b/sprout/config/suffix.hpp @@ -86,6 +86,15 @@ # define SPROUT_DEPRECATED #endif +// +// SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES +// +#if defined(SPROUT_NO_CXX11_TEMPLATE_ALIASES) +# define SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES +#elif defined(__INTEL_COMPILER) || defined(__ICL) || defined(__ICC) || defined(__ECC) +# define SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES +#endif + // // SPROUT_USE_EXPLICIT_CONVERSION_OPERATORS // SPROUT_EXPLICIT_CONVERSION diff --git a/sprout/index_tuple/index_n.hpp b/sprout/index_tuple/index_n.hpp index 935255fe..dddefdb4 100644 --- a/sprout/index_tuple/index_n.hpp +++ b/sprout/index_tuple/index_n.hpp @@ -18,13 +18,13 @@ namespace sprout { // index_n // uindex_n // -#if SPROUT_USE_TEMPLATE_ALIASES +#if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) template using index_n = sprout::integer_n; template using uindex_n = sprout::integer_n; -#else // #if SPROUT_USE_TEMPLATE_ALIASES +#else // #if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) template struct index_n : public sprout::integer_n::type @@ -36,7 +36,7 @@ namespace sprout { : public sprout::integer_n::type ::template transfer > {}; -#endif // #if SPROUT_USE_TEMPLATE_ALIASES +#endif // #if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) } // namespace sprout #endif // #ifndef SPROUT_INDEX_TUPLE_INDEX_N_HPP diff --git a/sprout/index_tuple/index_pack.hpp b/sprout/index_tuple/index_pack.hpp index 78f412a1..7037be08 100644 --- a/sprout/index_tuple/index_pack.hpp +++ b/sprout/index_tuple/index_pack.hpp @@ -18,13 +18,13 @@ namespace sprout { // index_pack // uindex_pack // -#if SPROUT_USE_TEMPLATE_ALIASES +#if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) template using index_pack = sprout::integer_pack; template using uindex_pack = sprout::integer_pack; -#else // #if SPROUT_USE_TEMPLATE_ALIASES +#else // #if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) template struct index_pack : public sprout::enable_make_indexes< @@ -40,7 +40,7 @@ namespace sprout { ::template transfer > > {}; -#endif // #if SPROUT_USE_TEMPLATE_ALIASES +#endif // #if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) } // namespace sprout #endif // #ifndef SPROUT_INDEX_TUPLE_INDEX_PACK_HPP diff --git a/sprout/index_tuple/index_range.hpp b/sprout/index_tuple/index_range.hpp index b5b530cd..09a298c8 100644 --- a/sprout/index_tuple/index_range.hpp +++ b/sprout/index_tuple/index_range.hpp @@ -17,7 +17,7 @@ namespace sprout { // index_range // uindex_range // -#if SPROUT_USE_TEMPLATE_ALIASES +#if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) template< sprout::index_t First, sprout::index_t Last, typename std::make_signed::type Step = sprout::detail::integer_range_default_step::value @@ -29,7 +29,7 @@ namespace sprout { typename std::make_signed::type Step = sprout::detail::integer_range_default_step::value > using uindex_range = sprout::integer_range; -#else // #if SPROUT_USE_TEMPLATE_ALIASES +#else // #if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) template< sprout::index_t First, sprout::index_t Last, typename std::make_signed::type Step = sprout::detail::integer_range_default_step::value @@ -47,7 +47,7 @@ namespace sprout { : public sprout::integer_range::type ::template transfer > {}; -#endif // #if SPROUT_USE_TEMPLATE_ALIASES +#endif // #if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) } // namespace sprout #endif // #ifndef SPROUT_INDEX_TUPLE_INDEX_RANGE_HPP diff --git a/sprout/index_tuple/index_sequence_for.hpp b/sprout/index_tuple/index_sequence_for.hpp index 103f3447..905f025a 100644 --- a/sprout/index_tuple/index_sequence_for.hpp +++ b/sprout/index_tuple/index_sequence_for.hpp @@ -15,15 +15,15 @@ namespace sprout { // // index_sequence_for // -#if SPROUT_USE_TEMPLATE_ALIASES +#if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) template using index_sequence_for = sprout::uindex_pack; -#else // #if SPROUT_USE_TEMPLATE_ALIASES +#else // #if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) template struct index_sequence_for : public sprout::uindex_pack {}; -#endif // #if SPROUT_USE_TEMPLATE_ALIASES +#endif // #if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) } // namespace sprout #endif // #ifndef SPROUT_INDEX_TUPLE_INDEX_SEQUENCE_FOR_HPP diff --git a/sprout/index_tuple/index_tuple.hpp b/sprout/index_tuple/index_tuple.hpp index 46a7a532..d9140afe 100644 --- a/sprout/index_tuple/index_tuple.hpp +++ b/sprout/index_tuple/index_tuple.hpp @@ -17,13 +17,13 @@ namespace sprout { // index_tuple // uindex_tuple // -#if SPROUT_USE_TEMPLATE_ALIASES +#if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) template using index_tuple = sprout::integer_sequence; template using uindex_tuple = sprout::integer_sequence; -#else // #if SPROUT_USE_TEMPLATE_ALIASES +#else // #if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) template struct index_tuple : public sprout::integer_sequence @@ -55,7 +55,7 @@ namespace sprout { return type(); } }; -#endif // #if SPROUT_USE_TEMPLATE_ALIASES +#endif // #if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) } // namespace sprout #endif // #ifndef SPROUT_INDEX_TUPLE_INDEX_TUPLE_HPP diff --git a/sprout/index_tuple/integer_n.hpp b/sprout/index_tuple/integer_n.hpp index f535d072..9076342f 100644 --- a/sprout/index_tuple/integer_n.hpp +++ b/sprout/index_tuple/integer_n.hpp @@ -79,15 +79,15 @@ namespace sprout { // // integer_range // -#if SPROUT_USE_TEMPLATE_ALIASES +#if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) template using integer_n = typename sprout::detail::integer_n::type; -#else // #if SPROUT_USE_TEMPLATE_ALIASES +#else // #if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) template struct integer_n : public sprout::detail::integer_n {}; -#endif // #if SPROUT_USE_TEMPLATE_ALIASES +#endif // #if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) } // namespace sprout #endif // #ifndef SPROUT_INDEX_TUPLE_INTEGER_N_HPP diff --git a/sprout/index_tuple/integer_pack.hpp b/sprout/index_tuple/integer_pack.hpp index 84e41086..b52c42b8 100644 --- a/sprout/index_tuple/integer_pack.hpp +++ b/sprout/index_tuple/integer_pack.hpp @@ -16,15 +16,15 @@ namespace sprout { // // integer_pack // -#if SPROUT_USE_TEMPLATE_ALIASES +#if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) template using integer_pack = sprout::make_integer_sequence::value>; -#else // #if SPROUT_USE_TEMPLATE_ALIASES +#else // #if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) template struct integer_pack : public sprout::make_integer_sequence {}; -#endif // #if SPROUT_USE_TEMPLATE_ALIASES +#endif // #if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) } // namespace sprout #endif // #ifndef SPROUT_INDEX_TUPLE_INTEGER_PACK_HPP diff --git a/sprout/index_tuple/integer_range.hpp b/sprout/index_tuple/integer_range.hpp index cfe93947..1baf5285 100644 --- a/sprout/index_tuple/integer_range.hpp +++ b/sprout/index_tuple/integer_range.hpp @@ -104,13 +104,13 @@ namespace sprout { // // integer_range // -#if SPROUT_USE_TEMPLATE_ALIASES +#if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) template< typename T, T First, T Last, typename std::make_signed::type Step = sprout::detail::integer_range_default_step::value > using integer_range = typename sprout::detail::integer_range::type; -#else // #if SPROUT_USE_TEMPLATE_ALIASES +#else // #if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) template< typename T, T First, T Last, typename std::make_signed::type Step = sprout::detail::integer_range_default_step::value @@ -118,7 +118,7 @@ namespace sprout { struct integer_range : public sprout::detail::integer_range {}; -#endif // #if SPROUT_USE_TEMPLATE_ALIASES +#endif // #if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) } // namespace sprout #endif // #ifndef SPROUT_INDEX_TUPLE_INTEGER_RANGE_HPP diff --git a/sprout/index_tuple/make_index_sequence.hpp b/sprout/index_tuple/make_index_sequence.hpp index 6d886ece..3331c342 100644 --- a/sprout/index_tuple/make_index_sequence.hpp +++ b/sprout/index_tuple/make_index_sequence.hpp @@ -16,15 +16,15 @@ namespace sprout { // // make_index_sequence // -#if SPROUT_USE_TEMPLATE_ALIASES +#if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) template using make_index_sequence = sprout::make_uindex_tuple; -#else // #if SPROUT_USE_TEMPLATE_ALIASES +#else // #if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) template struct make_index_sequence : public sprout::make_uindex_tuple {}; -#endif // #if SPROUT_USE_TEMPLATE_ALIASES +#endif // #if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) } // namespace sprout #endif // #ifndef SPROUT_INDEX_TUPLE_MAKE_INDEX_SEQUENCE_HPP diff --git a/sprout/index_tuple/make_index_tuple.hpp b/sprout/index_tuple/make_index_tuple.hpp index 205cce6c..289e4cd6 100644 --- a/sprout/index_tuple/make_index_tuple.hpp +++ b/sprout/index_tuple/make_index_tuple.hpp @@ -18,13 +18,13 @@ namespace sprout { // make_index_tuple // make_uindex_tuple // -#if SPROUT_USE_TEMPLATE_ALIASES +#if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) template using make_index_tuple = sprout::make_integer_sequence; template using make_uindex_tuple = sprout::make_integer_sequence; -#else // #if SPROUT_USE_TEMPLATE_ALIASES +#else // #if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) template struct make_index_tuple : public sprout::enable_make_indexes< @@ -40,7 +40,7 @@ namespace sprout { ::template transfer >::type > {}; -#endif // #if SPROUT_USE_TEMPLATE_ALIASES +#endif // #if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) } // namespace sprout #endif // #ifndef SPROUT_INDEX_TUPLE_MAKE_INDEX_TUPLE_HPP diff --git a/sprout/index_tuple/make_integer_sequence.hpp b/sprout/index_tuple/make_integer_sequence.hpp index ef15eac4..1e36953d 100644 --- a/sprout/index_tuple/make_integer_sequence.hpp +++ b/sprout/index_tuple/make_integer_sequence.hpp @@ -15,15 +15,15 @@ namespace sprout { // // make_integer_sequence // -#if SPROUT_USE_TEMPLATE_ALIASES +#if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) template using make_integer_sequence = sprout::integer_range; -#else // #if SPROUT_USE_TEMPLATE_ALIASES +#else // #if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) template struct make_integer_sequence : public sprout::integer_range {}; -#endif // #if SPROUT_USE_TEMPLATE_ALIASES +#endif // #if SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES) } // namespace sprout #endif // #ifndef SPROUT_INDEX_TUPLE_MAKE_INTEGER_SEQUENCE_HPP diff --git a/sprout/index_tuple/tuple.hpp b/sprout/index_tuple/tuple.hpp index af506f7c..07372a71 100644 --- a/sprout/index_tuple/tuple.hpp +++ b/sprout/index_tuple/tuple.hpp @@ -38,7 +38,7 @@ namespace std { typedef typename sprout::pack_element_c::type type; }; -#if !SPROUT_USE_TEMPLATE_ALIASES +#if !(SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES)) // // tuple_size // @@ -68,7 +68,7 @@ namespace std { struct tuple_element > : public std::tuple_element > {}; -#endif // #if SPROUT_USE_TEMPLATE_ALIASES +#endif // #if !(SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES)) #if defined(__clang__) # pragma clang diagnostic pop @@ -87,7 +87,7 @@ namespace sprout { return type(); } -#if !SPROUT_USE_TEMPLATE_ALIASES +#if !(SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES)) // // tuple_get // @@ -109,7 +109,7 @@ namespace sprout { typedef typename std::tuple_element >::type type; return type(); } -#endif // #if SPROUT_USE_TEMPLATE_ALIASES +#endif // #if !(SPROUT_USE_TEMPLATE_ALIASES && !defined(SPROUT_NO_TEMPLATE_ARGUMENT_DEDUCTION_WITH_ALIASES)) } // namespace sprout #endif // #ifndef SPROUT_INDEX_TUPLE_TUPLE_HPP