From f216259dc50e3a06164781e025bbb486cdc1dbaa Mon Sep 17 00:00:00 2001 From: Ilya Zakharevich Date: Wed, 24 Jan 2001 14:06:57 -0500 Subject: overload int() Message-ID: <20010124190657.A8512@math.ohio-state.edu> p4raw-id: //depot/perl@8545 --- t/lib/bigintpm.t | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 't/lib/bigintpm.t') diff --git a/t/lib/bigintpm.t b/t/lib/bigintpm.t index e76f246f18..dac6f5f4a0 100755 --- a/t/lib/bigintpm.t +++ b/t/lib/bigintpm.t @@ -9,7 +9,7 @@ use Math::BigInt; $test = 0; $| = 1; -print "1..278\n"; +print "1..283\n"; while () { chop; if (s/^&//) { @@ -25,6 +25,8 @@ while () { $try .= "-\$x;"; } elsif ($f eq "babs") { $try .= "abs \$x;"; + } elsif ($f eq "bint") { + $try .= "int \$x;"; } else { $try .= "\$y = new Math::BigInt \"$args[1]\";"; if ($f eq "bcmp"){ @@ -375,3 +377,9 @@ abc:NaN +0:-1 +8:-9 +281474976710656:-281474976710657 +&bint ++0:+0 ++1:+1 ++11111111111111111234:+11111111111111111234 +-1:-1 +-11111111111111111234:-11111111111111111234 -- cgit v1.2.1