pkgsrc-WIP-cvs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
CVS commit: wip/py-gmpy
Module name: wip
Committed by: jihbed
Date: Fri Jul 16 21:24:22 UTC 2010
Modified Files:
wip/py-gmpy: Makefile PLIST distinfo
Log Message:
wip-changes
==========
o update py-gmpy 1.12
Changes in gmpy 1.10
Number conversion rules have changed.
-------------------------------------
The arguments in operations involving mixed types are converted using the
following rules:
Integer --> Rational --> Floating-point
'int' 'Fraction' 'float'
'long' 'mpq' 'Decimal'
'mpz' 'mpf'
Old behavior:
mpz(1) + float(1.2) --> float(2.2)
mpz(1) + Decimal('1.2') --> mpz(2)
New behavior:
mpz(1) + float(1.2) --> mpf(2.2)
mpz(1) + Decimal('1.2') --> mpf(2.2)
As a side-effect of Python 3.x compatibility, coerce() is no longer supported.
The result of // will be an mpz if the arguments are Integer or Rational, but
will be an mpf if either argument is Floating-point.
The result of 'mpq'/'mpq' will be an 'mpq'. It will not be converted to an
'mpf'. This matches the behavior of the 'Fraction' type in Python 3.x.
The result of 'mpz'/'float' will an 'mpf' instead of a 'float'.
Type-specific methods require appropriate arguments.
----------------------------------------------------
If you call an 'mpq' specific method, i.e. gmpy.qdiv, the arguments are
required to be either integer or rational. Floating-point arguments are not
automatically converted to rational when an 'mpq' specific method is
called. Similarly, if you call an 'mpz' specific method, the arguments must
be integers.
Other bug fixes and changes
--------------------------
Corrected formating bug with mpf where last digit was missing.
The wording of some error messages has changed. The type of error has not
changed.
The result of gcdext may no longer be the "minimal" values. They result
does solve gcd(a,b) = ax + by. This is a side-effect of GMP 4.3 using a
different (faster) algorithm.
Unicode strings are now supported.
To generate a diff of this commit:
cvs -z3 rdiff -u -r1.2 -r1.3 wip/py-gmpy/PLIST wip/py-gmpy/distinfo
cvs -z3 rdiff -u -r1.5 -r1.6 wip/py-gmpy/Makefile
To view a diff of this commit:
http://pkgsrc-wip.cvs.sourceforge.net/pkgsrc-wip/wip/py-gmpy/PLIST?r1=1.2&r2=1.3
http://pkgsrc-wip.cvs.sourceforge.net/pkgsrc-wip/wip/py-gmpy/distinfo?r1=1.2&r2=1.3
http://pkgsrc-wip.cvs.sourceforge.net/pkgsrc-wip/wip/py-gmpy/Makefile?r1=1.5&r2=1.6
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
------------------------------------------------------------------------------
This SF.net email is sponsored by Sprint
What will you do first with EVO, the first 4G phone?
Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first
_______________________________________________
pkgsrc-wip-cvs mailing list
pkgsrc-wip-cvs%lists.sourceforge.net@localhost
https://lists.sourceforge.net/lists/listinfo/pkgsrc-wip-cvs
Home |
Main Index |
Thread Index |
Old Index