From: Tels Date: Sun, 16 Sep 2007 13:41:15 +0000 (+0200) Subject: fix bigint testsuite X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=f7f86b739109e8c852aaa336c415657dd196346e;p=p5sagit%2Fp5-mst-13.2.git fix bigint testsuite Message-Id: <200709161341.15574@bloodgate.com> p4raw-id: //depot/perl@31879 --- diff --git a/lib/Math/BigInt.pm b/lib/Math/BigInt.pm index 82da5f3..84af872 100644 --- a/lib/Math/BigInt.pm +++ b/lib/Math/BigInt.pm @@ -3796,6 +3796,12 @@ This method was added in v1.87 of Math::BigInt (June 2007). $x->bsqrt(); # calculate square-root +=head2 broot() + + $x->broot($N); + +Calculates the N'th root of C<$x>. + =head2 bfac() $x->bfac(); # factorial of $x (1*2*3*4*..$x) diff --git a/lib/Math/BigInt/t/bigfltpm.inc b/lib/Math/BigInt/t/bigfltpm.inc index 60b5cd2..4aa022c 100644 --- a/lib/Math/BigInt/t/bigfltpm.inc +++ b/lib/Math/BigInt/t/bigfltpm.inc @@ -8,7 +8,7 @@ my $z; while () { - chomp; + $_ =~ s/[\n\r]//g; # remove newlines $_ =~ s/#.*$//; # remove comments $_ =~ s/\s+$//; # trailing spaces next if /^$/; # skip empty lines & comments diff --git a/lib/Math/BigInt/t/bigintpm.inc b/lib/Math/BigInt/t/bigintpm.inc index f948156..87f31eb 100644 --- a/lib/Math/BigInt/t/bigintpm.inc +++ b/lib/Math/BigInt/t/bigintpm.inc @@ -42,7 +42,7 @@ my ($f,$z,$a,$exp,@a,$m,$e,$round_mode,$expected_class); while () { - chomp; + $_ =~ s/[\n\r]//g; # remove newlines next if /^#/; # skip comments if (s/^&//) { diff --git a/lib/Math/BigInt/t/calling.t b/lib/Math/BigInt/t/calling.t index d113d4e..3fee915 100644 --- a/lib/Math/BigInt/t/calling.t +++ b/lib/Math/BigInt/t/calling.t @@ -69,7 +69,7 @@ my $version = '1.76'; # adjust manually to match latest release my ($func,@args,$ans,$rc,$class,$try); while () { - chomp; + $_ =~ s/[\n\r]//g; # remove newlines next if /^#/; # skip comments if (s/^&//) { diff --git a/lib/Math/BigInt/t/mbimbf.inc b/lib/Math/BigInt/t/mbimbf.inc index a5ea3f6..b057eee 100644 --- a/lib/Math/BigInt/t/mbimbf.inc +++ b/lib/Math/BigInt/t/mbimbf.inc @@ -782,7 +782,7 @@ my ($ans1,$f,$a,$p,$xp,$yp,$xa,$ya,$try,$ans,@args); my $CALC = Math::BigInt->config()->{lib}; while () { - chomp; + $_ =~ s/[\n\r]//g; # remove newlines next if /^\s*(#|$)/; # skip comments and empty lines if (s/^&//) { diff --git a/lib/Math/BigInt/t/upgrade.inc b/lib/Math/BigInt/t/upgrade.inc index 3aa42ef..49eb0e9 100644 --- a/lib/Math/BigInt/t/upgrade.inc +++ b/lib/Math/BigInt/t/upgrade.inc @@ -52,7 +52,7 @@ my ($f,$z,$a,$exp,@a,$m,$e,$round_mode,$expected_class); while () { - chomp; + $_ =~ s/[\n\r]//g; # remove newlines next if /^#/; # skip comments if (s/^&//) {