Changeset 488056 in git for libpolys/coeffs/rmodulon.cc


Ignore:
Timestamp:
Dec 17, 2012, 1:10:48 PM (12 years ago)
Author:
Martin Lee <martinlee84@…>
Branches:
(u'fieker-DuVal', '117eb8c30fc9e991c4decca4832b1d19036c4c65')(u'spielwiese', 'b52fc4b2495505785981d640dcf7eb3e456778ef')
Children:
a453bfa3c5e9178b6ada6c3e4b3500f7b3e65b6f
Parents:
8c6bd4d4de4c46d6d974085a44f6e1530d956d5a
Message:
fix: more fixes to init of Z/*
File:
1 edited

Legend:

Unmodified
Added
Removed
  • libpolys/coeffs/rmodulon.cc

    r8c6bd4d r488056  
    5151  assume( (getCoeffType(r) == ID) || (getCoeffType (r) == ID2) );
    5252  ZnmInfo * info= (ZnmInfo *) p;
    53   r->modBase = (int_number) omAlloc(sizeof(mpz_t));
     53  r->modBase = (int_number) omAllocBin (gmp_nrz_bin);
    5454  mpz_init_set (r->modBase, info->base);
    5555
     
    578578{
    579579  /* clean up former stuff */
    580   //if (r->modBase   != NULL) mpz_clear(r->modBase);
    581580  if (r->modNumber != NULL) mpz_clear(r->modNumber);
    582581
    583582  r->modExponent= m;
    584   /* this is Z/m = Z/(m^1), hence set modBase = m, modExponent = 1: */
    585   //r->modBase = (int_number)omAllocBin(gmp_nrz_bin);
    586   //mpz_init(r->modBase);
    587   //mpz_set_ui(r->modBase, (unsigned long)m);
    588583  r->modNumber = (int_number)omAllocBin(gmp_nrz_bin);
    589584  mpz_init_set (r->modNumber, r->modBase);
Note: See TracChangeset for help on using the changeset viewer.