Skip to content

Commit 4bda2d7

Browse files
committed
Simplify nan path
1 parent 3f106a4 commit 4bda2d7

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

include/boost/decimal/decimal32_t.hpp

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2062,13 +2062,10 @@ constexpr auto operator/(Integer lhs, const decimal32_t rhs) noexcept
20622062

20632063
const auto rhs_fp {fpclassify(rhs)};
20642064

2065-
if (rhs_fp == FP_NAN)
2066-
{
2067-
return detail::check_non_finite(rhs);
2068-
}
2069-
20702065
switch (rhs_fp)
20712066
{
2067+
case FP_NAN:
2068+
return detail::check_non_finite(rhs);
20722069
case FP_INFINITE:
20732070
return sign ? -zero : zero;
20742071
case FP_ZERO:

0 commit comments

Comments
 (0)