Skip to content

Commit

Permalink
Fix libc++ accidentally picking the wrong overload of std::copysign
Browse files Browse the repository at this point in the history
  • Loading branch information
eliaskosunen committed May 24, 2024
1 parent 5c82b41 commit 863e042
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/scn/impl.h
Original file line number Diff line number Diff line change
Expand Up @@ -4099,9 +4099,9 @@ class float_reader : public numeric_reader<CharT>, public float_reader_base {
T setsign(T value) const
{
if (m_sign == sign_type::minus_sign) {
return std::copysign(value, -1.0);
return std::copysign(value, T{-1.0});
}
return std::copysign(value, 1.0);
return std::copysign(value, T{1.0});
}

template <typename T>
Expand Down

0 comments on commit 863e042

Please sign in to comment.