Changeset a52291 in git for factory/int_rat.h


Ignore:
Timestamp:
Nov 24, 2011, 2:35:53 PM (12 years ago)
Author:
Martin Lee <martinlee84@…>
Branches:
(u'spielwiese', 'fe61d9c35bf7c61f2b6cbf1b56e25e2f08d536cc')
Children:
8b46459e9dad8bec212484f1bfce347c45e41371
Parents:
1c48503bfae9bb885752ba741bd0a236df633d13
git-author:
Martin Lee <martinlee84@web.de>2011-11-24 14:35:53+01:00
git-committer:
Oleksandr Motsak <motsak@mathematik.uni-kl.de>2011-11-24 21:10:03+01:00
Message:
replacing MP_INT by mpz_t

Conflicts:

	factory/cf_factory.h
File:
1 edited

Legend:

Unmodified
Added
Removed
  • factory/int_rat.h

    r1c48503 ra52291  
    2727{
    2828private:
    29     MP_INT _num;
    30     MP_INT _den;
     29    mpz_t _num;
     30    mpz_t _den;
    3131    static int initialized;
    32     static MP_INT & MPQNUM( const InternalCF * const c );
    33     static MP_INT & MPQDEN( const InternalCF * const c );
    34     static void normalize( const MP_INT &, const MP_INT &, MP_INT &, MP_INT & );
     32    static mpz_ptr MPQNUM( const InternalCF * const c );
     33    static mpz_ptr MPQDEN( const InternalCF * const c );
     34    static void normalize( const mpz_ptr, const mpz_ptr, mpz_ptr, mpz_ptr );
    3535public:
    3636    InternalRational();
     
    4242    InternalRational( const int n, const int d );
    4343    InternalRational( const char * str );
    44     InternalRational( const MP_INT & );
    45     InternalRational( const MP_INT &, const MP_INT & );
     44    InternalRational( const mpz_ptr );
     45    InternalRational( const mpz_ptr , const mpz_ptr );
    4646    ~InternalRational();
    4747    InternalCF* deepCopyObject() const;
     
    100100    friend void gmp_numerator ( const CanonicalForm & f, mpz_ptr result );
    101101    friend void gmp_denominator ( const CanonicalForm & f, mpz_ptr result );
    102     friend CanonicalForm make_cf ( const MP_INT & n, const MP_INT & d );
     102    friend CanonicalForm make_cf ( const mpz_ptr n, const mpz_ptr d );
    103103};
    104104
    105 inline MP_INT & InternalRational::MPQNUM( const InternalCF * const c )
     105inline mpz_ptr InternalRational::MPQNUM( const InternalCF * const c )
    106106{
    107107    return (((InternalRational*)c)->_num);
    108108}
    109109
    110 inline MP_INT & InternalRational::MPQDEN( const InternalCF * const c )
     110inline mpz_ptr InternalRational::MPQDEN( const InternalCF * const c )
    111111{
    112112    return (((InternalRational*)c)->_den);
Note: See TracChangeset for help on using the changeset viewer.