Compare commits

...

2 Commits

Author SHA1 Message Date
Valentin Balaschenko
7c918d8122 improve packing of Number 2026-01-22 15:20:41 +00:00
Valentin Balaschenko
68fb4e7ad6 improve packing of Number 2026-01-22 14:19:02 +00:00

View File

@@ -213,9 +213,9 @@ class Number
using rep = std::int64_t; using rep = std::int64_t;
using internalrep = MantissaRange::rep; using internalrep = MantissaRange::rep;
bool negative_{false};
internalrep mantissa_{0}; internalrep mantissa_{0};
int exponent_{std::numeric_limits<int>::lowest()}; int exponent_{std::numeric_limits<int>::lowest()};
bool negative_{false};
public: public:
// The range for the exponent when normalized // The range for the exponent when normalized
@@ -524,7 +524,7 @@ inline constexpr Number::Number(
internalrep mantissa, internalrep mantissa,
int exponent, int exponent,
unchecked) noexcept unchecked) noexcept
: negative_(negative), mantissa_{mantissa}, exponent_{exponent} : mantissa_{mantissa}, exponent_{exponent}, negative_(negative)
{ {
} }