diff options
author | Jarkko Hietaniemi <jhi@iki.fi> | 2001-08-09 13:33:47 +0000 |
---|---|---|
committer | Jarkko Hietaniemi <jhi@iki.fi> | 2001-08-09 13:33:47 +0000 |
commit | 17baacb7566a50d23189ae645624597ecca41aab (patch) | |
tree | fdee0caf98819f5b0e760b66c072124616fc7fbd /lib/Math/BigInt/t/bigintpm.t | |
parent | 3521e4eeb75301e7c0e043f6cf0251e1b642eaa4 (diff) | |
download | perl-17baacb7566a50d23189ae645624597ecca41aab.tar.gz |
Upgrade to Math::BigInt 1.41.
p4raw-id: //depot/perl@11622
Diffstat (limited to 'lib/Math/BigInt/t/bigintpm.t')
-rwxr-xr-x | lib/Math/BigInt/t/bigintpm.t | 25 |
1 files changed, 5 insertions, 20 deletions
diff --git a/lib/Math/BigInt/t/bigintpm.t b/lib/Math/BigInt/t/bigintpm.t index e456a3e06b..b815aadc71 100755 --- a/lib/Math/BigInt/t/bigintpm.t +++ b/lib/Math/BigInt/t/bigintpm.t @@ -519,31 +519,16 @@ ok ($x,-3); ok (ref($x),'Math::Foo'); ############################################################################### -# test whether +inf eq inf - -$y = 1e1000000; # create inf, since bareword inf does not work -$x = Math::BigInt->new('+inf'); ok_inf ($x,$y); +# Test whether +inf eq inf +# This tried to test whether BigInt inf equals Perl inf. Unfortunately, Perl +# hasn't (before 5.7.3 at least) a consistent way to say inf, and some things +# like 1e100000 crash on some platforms. So simple test for 'inf' +$x = Math::BigInt->new('+inf'); ok ($x,'inf'); ############################################################################### # all tests done ############################################################################### - -# libc are confused what to call Infinity - -sub fix_inf { - $_[0] =~ s/^(inf(?:inity)?|\+\+)$/Inf/i; # HP-UX calls it "++" -} - -sub ok_inf { - my ($x, $y) = @_; - - fix_inf($x); - fix_inf($y); - - ok($x, $y); -} - # Perl 5.005 does not like ok ($x,undef) sub ok_undef |