Skip Menu |
 

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

Report information
The Basics
Id: 21412
Status: resolved
Priority: 0/
Queue: Math-BigInt

People
Owner: TELS [...] cpan.org
Requestors: peter.john.acklam [...] gmail.com
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in: 1.77
Fixed in: 1.78



Subject: as_int() and as_number() are supposed to do the same, but don't
Download (untitled) / with headers
text/plain 515b
Math::BigInt::VERSION is 1.77 Math::BigFloat::VERSION is 1.51 perl is v5.8.7 built for cygwin-thread-multi-64int According to the documentation, as_number() is an to alias_int() and they should do the same thing, i.e., return a Math::BigInt. They don't: $ perl -MMath::BigFloat -wle 'print ref Math::BigFloat->new("3")->as_number()' Math::BigInt $ perl -MMath::BigFloat -wle 'print ref Math::BigFloat->new("3")->as_int()' Math::BigFloat In the second case, a Math::BigFloat is returned, not a Math::BigInt.
Subject: Re: [rt.cpan.org #21412] as_int() and as_number() are supposed to do the same, but don't
Date: Sun, 10 Sep 2006 16:09:31 +0200
To: bug-Math-BigInt [...] rt.cpan.org
From: Tels <nospam-abuse [...] bloodgate.com>
Download (untitled) / with headers
text/plain 1.3k
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Moin, On Sunday 10 September 2006 14:43, Peter John Acklam via RT wrote: Show quoted text
> Sun Sep 10 08:43:22 2006: Request 21412 was acted upon. > According to the documentation, as_number() is an to alias_int() and > they should do the same thing, i.e., return a Math::BigInt. They don't:
Thank you for your report. I fixed that issue in my local copy, see here for a pre-release snapshot: http://bloodgate.com/perl/packages/devel/Math-BigInt-1.78.tar.gz perl -Ilib -MMath::BigFloat -wle 'print ref\ Math::BigFloat->new("3")->as_int()' Math::BigInt Best wishes, Tels - -- Signed on Sun Sep 10 16:08:18 2006 with key 0x93B84C15. Visit my photo gallery at http://bloodgate.com/photos/ PGP key on http://bloodgate.com/tels.asc or per email. "To get something done, a committee should consist of no more than three persons, two of them absent." -- Unknown -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2 (GNU/Linux) iQEVAwUBRQQcm3cLPEOTuEwVAQJYigf/Qj+9HHoFStkMNw7w00sdc4XZJnXf+Pda vhCJx4nxx3j650OwHNUda9PBKSWAA3u09E+veJFUxAh4zGuLPHz6ZLcJVBCGIr5e QCMrI7/3j3mMq37cDMB8dr2KDJWjSS7U0t5fCyOHudoCOJJqXDstNvpBfmEB2MAT G/WLtVgV2umPZYSFWERLLe3FuzV2aXp58xQg/5cCafrQDP95GgW1i+IxKAnrSU3Q gGKOrnluagwqwvd7pGbGrYd9jra6ZnBjpVIcD2qiVRXeezdb+9QQdrg6lxGXbVwB 4uTRiXUZulzZJbLvqMMK42r+tBdWHmDmJXROnsX15UwUNjd7fn/FIw== =+/Y5 -----END PGP SIGNATURE-----
From: pjacklam [...] online.no
Download (untitled) / with headers
text/plain 121b
It looks good now. I am in favour of tests, so some tests should probably be added. Otherwise I suggest this case closed.
This issue has been fixed in the released v1.78. Thank you for your report, Tels


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.