| /openbsd-src/gnu/usr.bin/perl/cpan/Math-BigRat/t/ |
| H A D | downgrade.t | |
| H A D | big_ap.t | |
| /openbsd-src/gnu/usr.bin/perl/cpan/Math-BigInt/t/ |
| H A D | downgrade.t | |
| H A D | isa.t | 9 use Math::BigInt::Subclass; 10 use Math::BigFloat::Subclass; 11 use Math::BigFloat::BareSubclass; 12 use Math::BigInt; 13 use Math::BigFloat; 15 my $class = "Math::BigInt::Subclass"; 16 my $LIB = "Math::BigInt::Calc"; 18 # Check that a subclass is still considered a Math::BigInt 19 isa_ok($class->new(123), 'Math::BigInt'); 21 # ditto for plain Math [all...] |
| H A D | bigintpm.t | 9 use Math::BigInt only => 'Calc'; 12 $CLASS = "Math::BigInt"; 13 $LIB = Math::BigInt -> config('lib'); # backend library 20 my $gcd0 = Math::BigInt::bgcd(-12, 18, 27); 21 isa_ok($gcd0, "Math::BigInt", "bgcd() as function"); 24 my $gcd1 = Math::BigInt->bgcd(-12, 18, 27); 25 isa_ok($gcd1, "Math::BigInt", "bgcd() as class method"); 28 $x = Math::BigInt -> new(-12); 30 isa_ok($gcd2, "Math::BigInt", "bgcd() as instance method"); 37 my $lcm0 = Math::BigInt::blcm(-12, 18, 27); [all …]
|
| H A D | upgrade.t | 9 use Math::BigInt; 10 use Math::BigFloat; 12 my $x = Math::BigInt -> new(9); 13 my $y = Math::BigInt -> new(4); 19 is(ref($zi), "Math::BigInt", "9/4 gives a Math::BigInt without upgrading"); 23 Math::BigInt -> upgrade("Math::BigFloat"); 26 is(ref($zf), "Math::BigFloat", "9/4 gives a Math [all...] |
| H A D | mbimbf.t | 12 use Math::BigInt only => 'Calc'; 13 use Math::BigFloat; 15 our $mbi = 'Math::BigInt'; 16 our $mbf = 'Math::BigFloat'; 21 # guaranteed in the Math::Big(Int|Float) (unless subclass chooses to support 24 Math::BigInt->round_mode("even"); # reset for tests 25 Math::BigFloat->round_mode("even"); # reset for tests 27 is($Math::BigInt::rnd_mode, "even", '$Math::BigInt::rnd_mode = "even"'); 28 is($Math [all...] |
| H A D | bigfltpm.t | 9 use Math::BigInt only => 'Calc'; 10 use Math::BigFloat; 13 $CLASS = "Math::BigFloat"; 14 $LIB = Math::BigInt -> config('lib'); # backend library 19 # bug #17447: Can't call method Math::BigFloat->bsub, not a valid method 20 my $c = Math::BigFloat->new('123.3'); 22 qq|\$c = Math::BigFloat -> new("123.3"); \$y = \$c -> bsub("123")|); 24 # Bug until Math::BigInt v1.86, the scale wasn't treated as a scalar: 25 $c = Math::BigFloat->new('0.008'); 26 my $d = Math::BigFloat->new(3); [all …]
|
| H A D | sub_mbf.t | 11 use Math::BigFloat::Subclass; 14 $CLASS = "Math::BigFloat::Subclass"; 25 # Check that subclass is a Math::BigFloat, but not a Math::Bigint 26 isa_ok($ms, 'Math::BigFloat'); 27 ok(!$ms -> isa('Math::BigInt'), 28 "An object of class '" . ref($ms) . "' isn't a 'Math::BigInt'"); 30 my $bf = Math::BigFloat -> new(23); # same as other
|
| H A D | upgradef.t | 9 package Math::BigFloat::Test; 11 use Math::BigFloat; 13 our @ISA = qw/Math::BigFloat Exporter/; 19 return if $class =~ /^Math::Big(Int|Float$)/; # we aren't one of these 34 # use Math::BigInt upgrade => 'Math::BigFloat'; 35 use Math::BigFloat upgrade => 'Math::BigFloat::Test'; 40 $CLASS = "Math::BigFloat"; 41 $EXPECTED_CLASS = "Math::BigFloat::Test"; 42 $LIB = "Math::BigInt::Calc"; # backend 44 is(Math::BigFloat->upgrade(), $EXPECTED_CLASS, [all …]
|
| H A D | new_overloaded.t | 3 # Math::BigFloat->new had a bug where it would assume any object is a 4 # Math::BigInt which broke overloaded non-Math::BigInt objects. 26 use Math::BigFloat; 31 my $bigfloat = Math::BigFloat->new($overloaded_num); 32 is($bigfloat, 2.23, 'Math::BigFloat->new() accepts overloaded numbers'); 34 my $bigint = Math::BigInt->new(Overloaded::Num->new(3)); 35 is($bigint, 3, 'Math::BigInt->new() accepts overloaded numbers'); 37 is(Math::BigFloat->new($bigint), 3, 38 'Math::BigFloat->new() accepts a Math::BigInt');
|
| H A D | use_mbfw.t | 3 # check that using Math::BigFloat with "with" and "lib" at the same time works 14 # completely, for instance, when it is a 100% replacement for Math::BigInt, but 17 # Math::BigFloat hands the lib properly down, any more is outside out testing 20 use Math::BigFloat with => 'Math::BigInt::Subclass', 23 is(Math::BigFloat->config("with"), 'Math::BigInt::BareCalc', 24 'Math::BigFloat->config("with")'); 26 # is($Math::BigInt::Subclass::lib, 'BareCalc'); 29 is(Math::BigInt->config("lib"), 'Math::BigInt::BareCalc', 30 'Math::BigInt->config("lib")');
|
| /openbsd-src/gnu/usr.bin/perl/cpan/bignum/t/ |
| H A D | down-mbi-up-mbf.t | 10 is(bignum -> downgrade(), "Math::BigInt", 11 "bignum's downgrade class is Math::BigInt"); 12 is(bignum -> upgrade(), "Math::BigFloat", 13 "bignum's upgrade class is Math::BigFloat"); 15 is(Math::BigFloat -> downgrade(), "Math::BigInt", 16 "Math::BigFloat's downgrade class is Math::BigInt"); 17 is(Math::BigInt -> upgrade(), "Math::BigFloat", 18 "Math::BigInt's upgrade class is Math::BigFloat"); 25 is(ref($i1), "Math::BigInt", "literal $i1 is a Math::BigInt"); 26 is(ref($f1), "Math::BigFloat", "literal $f1 is a Math::BigFloat"); [all …]
|
| H A D | down-mbi-up-mbr.t | 9 eval "use Math::BigRat"; 10 plan skip_all => 'Math::BigRat required for these tests' if $@; 15 use bignum upgrade => "Math::BigRat"; 17 is(bignum -> downgrade(), "Math::BigInt", 18 "bignum's upgrade class is Math::BigInt"); 19 is(bignum -> upgrade(), "Math::BigRat", 20 "bignum's downgrade class is Math::BigInt"); 22 is(Math::BigInt -> upgrade(), "Math::BigRat", 23 "Math::BigInt's upgrade class is Math::BigRat"); 24 is(Math::BigRat -> downgrade(), "Math::BigInt", [all …]
|
| H A D | scope-nested-const.t | 17 is(ref(hex("1")), "Math::BigInt", 'ref(hex("1"))'); 18 is(ref(oct("1")), "Math::BigInt", 'ref(oct("1"))'); 23 is(ref(hex("1")), "Math::BigFloat", 'ref(hex("1"))'); 24 is(ref(oct("1")), "Math::BigFloat", 'ref(oct("1"))'); 29 is(ref(hex("1")), "Math::BigRat", 'ref(hex("1"))'); 30 is(ref(oct("1")), "Math::BigRat", 'ref(oct("1"))'); 38 is(ref(hex("1")), "Math::BigFloat", 'ref(hex("1"))'); 39 is(ref(oct("1")), "Math::BigFloat", 'ref(oct("1"))'); 47 is(ref(hex("1")), "Math::BigInt", 'ref(hex("1"))'); 48 is(ref(oct("1")), "Math::BigInt", 'ref(oct("1"))'); [all …]
|
| H A D | scope-nested-hex-oct.t | 17 is(ref(hex("1")), "Math::BigInt", 'ref(hex("1"))'); 18 is(ref(oct("1")), "Math::BigInt", 'ref(oct("1"))'); 23 is(ref(hex("1")), "Math::BigFloat", 'ref(hex("1"))'); 24 is(ref(oct("1")), "Math::BigFloat", 'ref(oct("1"))'); 29 is(ref(hex("1")), "Math::BigRat", 'ref(hex("1"))'); 30 is(ref(oct("1")), "Math::BigRat", 'ref(oct("1"))'); 38 is(ref(hex("1")), "Math::BigFloat", 'ref(hex("1"))'); 39 is(ref(oct("1")), "Math::BigFloat", 'ref(oct("1"))'); 47 is(ref(hex("1")), "Math::BigInt", 'ref(hex("1"))'); 48 is(ref(oct("1")), "Math::BigInt", 'ref(oct("1"))'); [all …]
|
| H A D | const-bigfloat.t | 28 my $class = "Math::BigFloat"; 32 # The following tests should be identical for Math::BigInt, Math::BigFloat and 33 # Math::BigRat. 39 is(ref($x), "Math::BigFloat", 40 "value is a Math::BigInt or Math::BigInt::Lite"); 54 is(ref($x), "Math::BigFloat", 55 "value is a Math::BigInt or Math::BigInt::Lite"); 65 is(ref($x), "Math::BigFloat", 66 "value is a Math::BigInt or Math::BigInt::Lite"); 72 is(ref($x), "Math::BigFloat", [all …]
|
| H A D | const-bignum.t | 28 my $class = "Math::BigFloat"; 32 # The following tests should be identical for Math::BigInt, Math::BigFloat and 33 # Math::BigRat. 39 like(ref($x), qr/^Math::BigInt(::Lite)?$/, 40 "value is a Math::BigInt or Math::BigInt::Lite"); 49 like(ref($x), qr/^Math::BigInt(::Lite)?$/, 50 "value is a Math::BigInt or Math::BigInt::Lite"); 55 like(ref($x), qr/^Math::BigInt(::Lite)?$/, 56 "value is a Math::BigInt or Math::BigInt::Lite"); 66 like(ref($x), qr/^Math::BigInt(::Lite)?$/, [all …]
|
| H A D | down-mbi-up-undef.t | 9 eval "use Math::BigRat"; 10 plan skip_all => 'Math::BigRat required for these tests' if $@; 17 is(bignum -> downgrade(), "Math::BigInt", 18 "bignum's upgrade class is Math::BigInt"); 22 is(Math::BigInt -> upgrade(), undef, 23 "Math::BigInt's upgrade class is undefined"); 24 is(Math::BigFloat -> downgrade(), "Math::BigInt", 25 "Math::BigFloat's downgrade class is Math::BigInt"); 32 is(ref($i1), "Math::BigInt", "literal $i1 is a Math::BigInt"); 33 is(ref($f1), "Math::BigFloat", "literal $f1 is a Math::BigFloat"); [all …]
|
| H A D | down-undef-up-mbf.t | 12 is(bignum -> upgrade(), "Math::BigFloat", 13 "bignum's upgrade class is Math::BigFloat"); 15 is(Math::BigFloat -> downgrade(), undef, 16 "Math::BigFloat's downgrade class is undefined"); 17 is(Math::BigInt -> upgrade(), "Math::BigFloat", 18 "Math::BigInt's upgrade class is Math::BigFloat"); 25 is(ref($i1), "Math::BigInt", "literal $i1 is a Math::BigInt"); 26 is(ref($f1), "Math::BigFloat", "literal $f1 is a Math::BigFloat"); 28 # Verify that the result is upgraded to a Math::BigFloat. 31 is(ref($i1/$i2), "Math::BigFloat", [all …]
|
| H A D | const-bigrat.t | 28 my $class = "Math::BigRat"; 32 # The following tests should be identical for Math::BigInt, Math::BigFloat and 33 # Math::BigRat. 39 is(ref($x), "Math::BigRat", "value is a Math::BigRat"); 53 is(ref($x), "Math::BigRat", "value is a Math::BigRat"); 63 is(ref($x), "Math::BigRat", "value is a Math::BigRat"); 69 is(ref($x), "Math::BigRat", "value is a Math::BigRat"); 87 is(ref($x), "Math::BigRat", "value is a Math::BigRat"); 93 is(ref($x), "Math::BigRat", "value is a Math::BigRat"); 108 is(ref($x), "Math::BigRat", "value is a Math::BigRat"); [all …]
|
| /openbsd-src/gnu/usr.bin/perl/cpan/Math-BigInt/t/Math/BigInt/ |
| H A D | Subclass.pm | 3 # test subclassing Math::BigInt 5 package Math::BigInt::Subclass; 10 use Math::BigInt; 12 our @ISA = qw(Math::BigInt); 21 our $accuracy = undef; # or Math::BigInt::Subclass -> accuracy(); 22 our $precision = undef; # or Math::BigInt::Subclass -> precision(); 23 our $round_mode = "even"; # or Math::BigInt::Subclass -> round_mode(); 24 our $div_scale = 40; # or Math::BigInt::Subclass -> div_scale(); 27 *objectify = \&Math::BigInt::objectify;
|
| /openbsd-src/gnu/usr.bin/perl/cpan/Math-BigRat/t/Math/BigRat/ |
| H A D | Test.pm | |
| /openbsd-src/gnu/usr.bin/perl/cpan/Math-BigInt-FastCalc/t/ |
| H A D | leak.t | 11 use Math::BigInt::FastCalc; 14 package Math::BigInt::FastCalc::LeakCheck; 16 use Math::BigInt::FastCalc; 17 our @ISA = qw< Math::BigInt::FastCalc >; 29 my $num = Math::BigInt::FastCalc::LeakCheck->$method(); 30 bless $num, "Math::BigInt::FastCalc::LeakCheck"; 35 my $num = Math::BigInt::FastCalc->_zero(); 40 my $rc = Math::BigInt::FastCalc->$method($num); 41 bless \$rc, "Math::BigInt::FastCalc::LeakCheck"; 46 my $num_10 = Math::BigInt::FastCalc->_ten(); [all …]
|
| /openbsd-src/gnu/usr.bin/perl/dist/Math-Complex/ |
| H A D | ChangeLog | 3 * Don't declare "tan" operator overloading on Math::Complex 9 * Release Math::Complex 1.59 + Math::Trig 1.23. 26 * Release Math::Complex 1.58 + Math::Trig 1.22. 40 * Release Math::Complex 1.57 + Math::Trig 1.21. 47 * Release Math::Complex 1.56 + Math::Trig 1.20. 56 * Release Math::Complex 1.55 + Math::Trig 1.19. 70 * Release Math::Complex 1.54 + Math::Trig 1.18. 75 "#34605: Math::Trig(3pm) man page feedback" 83 "#34269: Math::Trig::great_circle_destination" 88 * Release Math::Complex 1.53 + Math::Trig 1.17. [all …]
|