YoushouldhavereceivedcopiesoftheGNUGeneralPublicLicenseandthe GNULesserGeneralPublicLicensealongwiththeGNUMPLibrary.Ifnot,
see https://www.gnu.org/licenses/. */
#include"gmp-impl.h"
void *
_mpz_realloc (mpz_ptr m, mp_size_t new_alloc)
{
mp_ptr mp;
/* Never allocate zero space. */
new_alloc = MAX (new_alloc, 1);
if (sizeof (mp_size_t) == sizeof (int))
{ if (UNLIKELY (new_alloc > ULONG_MAX / GMP_NUMB_BITS))
MPZ_OVERFLOW;
} else
{ if (UNLIKELY (new_alloc > INT_MAX))
MPZ_OVERFLOW;
}
/* Don't create an invalid number; if the current value doesn't fit after
reallocation, clear it to 0. */ if (UNLIKELY (ABSIZ (m) > new_alloc))
SIZ (m) = 0;
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.