Please sign in to comment.
Make various functions work with bigints
A bug report reported by Dana Jacobsen reported that bigint was incompatible with Math::Primality, so we stringify our input so we can accept any object that has a stringification method. We also declare a min Perl version of 5.8, which is when bigint appeared in core.
- Loading branch information...
Showing with 23 additions and 5 deletions.
|@@ -0,0 +1,17 @@|
|+use Math::Primality qw/:all/;|
|+ok(is_prime(18446744073709551629), 'is_prime() works with bigint');|
|+ok(is_pseudoprime(18446744073709551629), 'is_pseudoprime() works with bigint');|
|+ok(is_pseudoprime(18446744073709551629, 3), 'is_pseudoprime(x,3) works with bigint');|
|+ok(is_strong_lucas_pseudoprime(18446744073709551629), 'is_strong_lucas_pseudoprime() works with bigint');|