aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTomasz Kramkowski <tk@the-tk.com>2021-11-07 22:20:38 +0000
committerTomasz Kramkowski <tk@the-tk.com>2021-11-07 22:20:38 +0000
commitf38ce04c0ab9b0b4b93ad6d79ce1d9410201611d (patch)
treeb1cf3e38a532e7948c11ed7a2093bfa3a16a7025
parent383c232bc2f1661923177437e48ea4cf6bd4e304 (diff)
downloadpack-f38ce04c0ab9b0b4b93ad6d79ce1d9410201611d.tar.gz
pack-f38ce04c0ab9b0b4b93ad6d79ce1d9410201611d.tar.xz
pack-f38ce04c0ab9b0b4b93ad6d79ce1d9410201611d.zip
ieee754b.c: small cleanup
-rw-r--r--ieee754b.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/ieee754b.c b/ieee754b.c
index 865f79e..07c92bf 100644
--- a/ieee754b.c
+++ b/ieee754b.c
@@ -20,12 +20,10 @@ type ieee754b##total##_deserialise(uintmax_t b) \
n = b & BITMASK(nfrac); \
\
if (exp == BITMASK(nexp)) { \
- if (n) { \
- return NAN; \
- } else { \
- return isneg ? -INFINITY : INFINITY; \
- } \
- } else if (exp == 0) { \
+ if (n) return NAN; \
+ return isneg ? -INFINITY : INFINITY; \
+ } \
+ if (exp == 0) { \
if (n == 0) \
return isneg ? -0.0 : 0.0; \
exp = -(int)(BITMASK(nexp) / 2 - 1); \