Debian Codegraph @

debian/patches/mpz-size-check

raw
1 Author: Gábor Németh <[email protected]>
2 Subject: Remove erroneous assert
3 Forwarded: https://github.com/bitwuzla/bitwuzla/commit/56671333
4
5 Zero mpz_size is valid, it means the stored value is zero.
6 All GMP functions will handle it correctly.
7 --- a/src/util/gmp_utils.cpp
8 +++ b/src/util/gmp_utils.cpp
9 @@ -44,7 +44,6 @@ mpz_get_ull(const mpz_t op)
10 return limb;
11 }
12 assert(mp_bits_per_limb == 32);
13 - assert(mpz_size(op) >= 1);
14 uint64_t limb_lo = static_cast<uint64_t>(mpz_getlimbn(op, 0));
15 uint64_t limb_hi = 0;
16 if (mpz_size(op) >= 2)