This queue is for tickets about the Math-BigInt CPAN distribution.

Report information
The Basics
Id:
130720
Status:
open
Priority:
Low/Low
Queue:

People
Owner:
Nobody in particular
Requestors:
ANDK [...] cpan.org
Cc:
AdminCc:

BugTracker
Severity:
(no value)
Broken in:
1.999817
Fixed in:
(no value)



Subject: 1.999817 breaks the tests of CryptX, Math-BigInt-Lite, and Math-Counting
As per subject. Involved distros: MIK/CryptX-0.064.tar.gz GJACKLAM/Math-BigInt-Lite-0.18.tar.gz MENE/Math-Counting-0.1305.tar.gz A sample fail report for CryptX: http://www.cpantesters.org/cpan/report/d7f2f25c-ed85-11e9-84a2-b83f75811fd8 (at the moment not reachable). Sample fail reports for Math-BigInt-Lite and Math-Counting are currently not publicly available, since cpantesters has a major outage.
Thanks for notifying me! I tested Math-BigInt-1.999817 against Math-BigInt-Lite, so that is a fail that suprises me. Anyway, I will look into this.
All failed tests in CryptX, Math-BigInt-Lite, and Math-Counting are due to a change in the bpow() method (and the overloaded ** operator) regarding non-integer results. When a Math::BigInt operation results in a non-integer, the output is either truncated (i.e., rounded towards zero) or upgraded, if upgrading is enabled. The bpow() method did not adhere to this and returned NaN for things like 2**(-3). Compare this to explicitly computing 1/8, which returned 0. In 1.999817 this inconsistency was removed. So now, 2**(-3) and 1/(2**3) give the same result, i.e., 0. I consider this change in Math-BigInt to be a bug fix. I suggest the test suits for CryptX, Math-BigInt-Lite, and Math-Counting are updated to reflect this improvement of Math-BigInt.
Could you find out why your own testing with Math-BigInt-Lite did not fail? Maybe there's something hidden below the surface?
On Fri Oct 18 22:52:55 2019, ANDK wrote:
Show quoted text
> Could you find out why your own testing with Math-BigInt-Lite did not > fail? Maybe there's something hidden below the surface?
I was unfortunately testing against my private Math-BigInt-Lite repo, which had been modified since the 0.18 release to reflect the changes to bpow()/**. When I test against the 0.18 release I see all the same failed tests.
Thanks for the heads up. Fixed in Math-Counting-0.1306 now. - GENE


This service runs on Request Tracker, is sponsored by The Perl Foundation, and maintained by Best Practical Solutions.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.