Skip to content

Commit

Permalink
Workaround showding template warning
Browse files Browse the repository at this point in the history
  • Loading branch information
jk-jeon committed Mar 18, 2024
1 parent 3ace526 commit ae7c3ce
Showing 1 changed file with 12 additions and 9 deletions.
21 changes: 12 additions & 9 deletions include/dragonbox/dragonbox.h
Original file line number Diff line number Diff line change
Expand Up @@ -2522,7 +2522,9 @@ namespace jkj {
bool parity;
bool is_integer;
};
template <class FloatFormat, class Dummy = void>
// FloatFormat2 is supposed to be FloatFormat, but need to use a different name to avoid
// shadowing.
template <class FloatFormat2, class Dummy = void>
struct compute_mul_impl;

//// The main algorithm assumes the input is a normal/subnormal finite number
Expand Down Expand Up @@ -3357,10 +3359,10 @@ namespace jkj {
operator()(Args... args) noexcept {
return impl<typename FloatTraits::format, typename FloatTraits::carrier_uint>::
template compute_nearest_normal<
unsigned_return_type, typename IntervalTypeProvider::normal_interval_type,
typename PolicyHolder::trailing_zero_policy,
typename PolicyHolder::binary_to_decimal_rounding_policy,
typename PolicyHolder::cache_policy>(args...);
unsigned_return_type, typename IntervalTypeProvider::normal_interval_type,
typename PolicyHolder::trailing_zero_policy,
typename PolicyHolder::binary_to_decimal_rounding_policy,
typename PolicyHolder::cache_policy>(args...);
}
};

Expand Down Expand Up @@ -3454,8 +3456,8 @@ namespace jkj {
signed_significand_bits,
detail::impl<typename FloatTraits::format, typename FloatTraits::carrier_uint>::
template compute_left_closed_directed<
unsigned_return_type, typename PolicyHolder::trailing_zero_policy,
typename PolicyHolder::cache_policy>(two_fc, exponent));
unsigned_return_type, typename PolicyHolder::trailing_zero_policy,
typename PolicyHolder::cache_policy>(two_fc, exponent));
}
else {
#if JKJ_HAS_IF_CONSTEXPR
Expand All @@ -3481,8 +3483,9 @@ namespace jkj {
signed_significand_bits,
detail::impl<typename FloatTraits::format, typename FloatTraits::carrier_uint>::
template compute_right_closed_directed<
unsigned_return_type, typename PolicyHolder::trailing_zero_policy,
typename PolicyHolder::cache_policy>(two_fc, exponent, shorter_interval));
unsigned_return_type, typename PolicyHolder::trailing_zero_policy,
typename PolicyHolder::cache_policy>(two_fc, exponent,
shorter_interval));
}
}

Expand Down

0 comments on commit ae7c3ce

Please sign in to comment.