Skip to content

Commit c188704

Browse files
committed
I won't never give up, no, never give up, no
1 parent 432a3d1 commit c188704

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

std/haxe/math/bigint/BigInt.hx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,9 @@ abstract BigInt(BigInt_) {
3939
//-----------------------------------------------------------------------
4040
// Private constants
4141
//-----------------------------------------------------------------------
42+
#if !cppia
4243
private static var SMALL_PRIMES_PRODUCT:BigInt = BigInt.fromString("1451887755777639901511587432083070202422614380984889313550570919659315177065956574359078912654149167643992684236991305777574330831666511589145701059710742276692757882915756220901998212975756543223550490431013061082131040808010565293748926901442915057819663730454818359472391642885328171302299245556663073719855");
43-
44+
#end
4445
//-----------------------------------------------------------------------
4546
// Public interface
4647
//-----------------------------------------------------------------------

std/haxe/math/bigint/BigInt_.hx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -567,11 +567,13 @@ class BigInt_ {
567567
bytes.set(0, bytes.get(0) | (1 << (7 - excessBits)));
568568
bytes.set(bytes.length - 1, bytes.get(bytes.length - 1) | 1);
569569
r.setFromBigEndianBytesSigned(bytes);
570+
#if !cppia
570571
if (bits > 10) {
571572
while (!equals2Int(r.gcd(BigInt.SMALL_PRIMES_PRODUCT), 1)) {
572573
BigIntArithmetic.addInt(r, r, 2);
573574
}
574575
}
576+
#end
575577
} while (!r.isProbablePrime(tolerance));
576578
if (r.sign() < 0)
577579
BigIntArithmetic.negate(r, r);

0 commit comments

Comments
 (0)