From: H.Merijn Brand Date: Fri, 8 Feb 2008 13:27:45 +0000 (+0000) Subject: Update to Math::Complex 1.49 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=9f4452f71a1756177e8cd3228d29c9b25d66f982;p=p5sagit%2Fp5-mst-13.2.git Update to Math::Complex 1.49 p4raw-id: //depot/perl@33253 --- diff --git a/lib/Math/Complex.pm b/lib/Math/Complex.pm index 819a63d..4373681 100644 --- a/lib/Math/Complex.pm +++ b/lib/Math/Complex.pm @@ -9,11 +9,12 @@ package Math::Complex; use vars qw($VERSION @ISA @EXPORT @EXPORT_OK %EXPORT_TAGS $Inf); -$VERSION = 1.48; +$VERSION = 1.49; BEGIN { # For 64-bit doubles, anyway. my $IEEE_DBL_MAX = eval "1.7976931348623157e+308"; + my $BIGGER_THAN_THIS = 1e99; # Must find something bigger than this. if ($^O eq 'unicosmk') { $Inf = $IEEE_DBL_MAX; } else { @@ -22,26 +23,26 @@ BEGIN { for my $t ( 'exp(999)', '9**9**9', - '1e999', 'inf', 'Inf', 'INF', 'infinity', 'Infinity', 'INFINITY', + '1e999', ) { local $SIG{FPE} = { }; local $^W = 0; my $i = eval "$t+1.0"; - if ($i =~ /inf/i && $i > 1e+99) { + if (defined $i && $i > $BIGGER_THAN_THIS) { $Inf = $i; last; } } $Inf = $IEEE_DBL_MAX unless defined $Inf; # Oh well, close enough. - die "Could not get Infinity" unless $Inf > 1e99; + die "Could not get Infinity" unless $Inf > $BIGGER_THAN_THIS; } - print "# On this machine, Inf = '$Inf'\n"; + # print "# On this machine, Inf = '$Inf'\n"; } use strict; diff --git a/lib/Math/Complex.t b/lib/Math/Complex.t index c914331..611a476 100755 --- a/lib/Math/Complex.t +++ b/lib/Math/Complex.t @@ -13,7 +13,7 @@ BEGIN { } } -use Math::Complex 1.48; +use Math::Complex 1.49; use vars qw($VERSION); diff --git a/lib/Math/Trig.pm b/lib/Math/Trig.pm index 76feca7..a8d94e2 100644 --- a/lib/Math/Trig.pm +++ b/lib/Math/Trig.pm @@ -10,14 +10,14 @@ package Math::Trig; use 5.005; use strict; -use Math::Complex 1.48; +use Math::Complex 1.49; use Math::Complex qw(:trig :pi); use vars qw($VERSION $PACKAGE @ISA @EXPORT @EXPORT_OK %EXPORT_TAGS); @ISA = qw(Exporter); -$VERSION = 1.13; +$VERSION = 1.14; my @angcnv = qw(rad2deg rad2grad deg2rad deg2grad diff --git a/lib/Math/Trig.t b/lib/Math/Trig.t index 7b0d7cf..f5e6010 100755 --- a/lib/Math/Trig.t +++ b/lib/Math/Trig.t @@ -28,8 +28,8 @@ BEGIN { plan(tests => 153); -use Math::Trig 1.13; -use Math::Trig 1.13 qw(:pi Inf); +use Math::Trig 1.14; +use Math::Trig 1.14 qw(:pi Inf); my $pip2 = pi / 2;