diff --git a/au/code/au/magnitude.hh b/au/code/au/magnitude.hh index 1be7957e..f93e3cbd 100644 --- a/au/code/au/magnitude.hh +++ b/au/code/au/magnitude.hh @@ -378,7 +378,7 @@ constexpr MagRepresentationOrError root(T x, std::uintmax_t n) { // Always use `long double` for intermediate computations. We don't ever expect people to be // calling this at runtime, so we want maximum accuracy. long double lo = 1.0; - long double hi = x; + long double hi = static_cast(x); // Do a binary search to find the closest value such that `checked_int_pow` recovers the input. //