Skip to content

Commit

Permalink
Restrict GMP OOM tests to platforms with 64-bits longs.
Browse files Browse the repository at this point in the history
  • Loading branch information
maleadt committed Sep 11, 2023
1 parent c704454 commit 2b96e8b
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions test/gmp.jl
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,10 @@ ee = typemax(Int64)
@test BigInt <: Signed
@test big(1) isa Signed

@test_throws OutOfMemoryError big(96608869069402268615522366320733234710)^16374500563449903721
@test_throws OutOfMemoryError 555555555555555555555555555555555555555555555555555^55555555555555555
if sizeof(Culong) >= 8
@test_throws OutOfMemoryError big(96608869069402268615522366320733234710)^16374500563449903721
@test_throws OutOfMemoryError 555555555555555555555555555555555555555555555555555^55555555555555555
end

let x = big(1)
@test signed(x) === x
Expand Down

0 comments on commit 2b96e8b

Please sign in to comment.