Skip Menu |
 

This queue is for tickets about the bignum CPAN distribution.

Report information
The Basics
Id: 105560
Status: open
Priority: 0/
Queue: bignum

People
Owner: Nobody in particular
Requestors: shimada_d [...] yahoo.co.jp
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: logarithm function returns NaN. atan2 function freezes.
Date: Tue, 30 Jun 2015 03:46:01 +0900
To: <bug-bignum [...] rt.cpan.org>
From: <shimada_d [...] yahoo.co.jp>
Download (untitled) / with headers
text/plain 827b
Hello. I report 2 bugs. * log() returns NaN. * atan2() function freezes. Sample is the following. ------------------------------------------------------------------ $ perl -Mbignum -le "print log(7)" NaN $ perl -Mbignum -le "print atan2(7, 2)" !!!! no return !!!! ------------------------------------------------------------------------------------------- Environment is the following. ------------------------------------------------------------- $ perl -Mbignum=v bignum v0.39 Math::BigInt v1.9997 lib => Math::BigInt::Calc v1.9997 Math::BigFloat v1.9997 $ perl -v|perl -p00e"last}{" This is perl 5, version 22, subversion 0 (v5.22.0) built for MSWin32-x86-multi-thread-64int ------------------------------------------------------------------------------------------- Thank you.
Download (untitled) / with headers
text/plain 602b
On 2015-06-29 14:46:18, shimada_d@yahoo.co.jp wrote: Show quoted text
> Hello. I report 2 bugs. > * log() returns NaN. > * atan2() function freezes. > > Sample is the following. > ------------------------------------------------------------------ > $ perl -Mbignum -le "print log(7)" > NaN
This looks like a regression: $ perl5.22.0 -Mbignum -le "print log(7)" NaN $ perl5.20.2 -Mbignum -le "print log(7)" 1.945910149055313305105352743443179729637 Show quoted text
> $ perl -Mbignum -le "print atan2(7, 2)" > !!!! no return !!!!
This does not look like a regression --- I found no perl (down to 5.8.9) where this oneliner worked.
Download (untitled) / with headers
text/plain 412b
The problem with the log() function was introduced by the commit http://perl5.git.perl.org/perl.git/commit/0f9d285877728dbba8969165d18f9a8b12ff68fc A quick look tells me that the loop in objectify() should contain # Don't do anything with undefs. next unless defined($a[$i]); This was present in earlier versions objectify(), but was removed for some reason. I will add a test case and submit a patch.


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

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