File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed
include/boost/math/policies Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -1007,14 +1007,19 @@ struct is_noexcept_error_policy
1007
1007
// For example if a special function for float promotes to double, we don't want the next
1008
1008
// function in the call chain to then promote to long double
1009
1009
template <typename Policy>
1010
- using make_forwarding_policy =
1010
+ struct make_forwarding_policy
1011
+ {
1012
+ static_assert (detail::is_valid_policy<Policy>::value, " Policy must be valid to make a forwarding policy" );
1013
+
1014
+ using type =
1011
1015
typename policies::normalise<
1012
1016
Policy,
1013
1017
policies::promote_float<false >,
1014
1018
policies::promote_double<false >,
1015
1019
policies::discrete_quantile<>,
1016
1020
policies::assert_undefined<>
1017
1021
>::type;
1022
+ };
1018
1023
1019
1024
template <typename Policy>
1020
1025
using make_forwarding_policy_t = typename make_forwarding_policy<Policy>::type;
You can’t perform that action at this time.
0 commit comments