Skip to content

Commit

Permalink
Simplify test task & possibly fix 32 bit (#60)
Browse files Browse the repository at this point in the history
  • Loading branch information
konsumlamm authored Jan 3, 2022
1 parent 211b405 commit 75b08a7
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions bigints.nimble
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ srcDir = "src"
requires "nim >= 1.4.0"

task test, "Test bigints":
exec "nim r --backend:c tests/tbigints.nim"
exec "nim r --backend:c tests/tbugs.nim"
exec "nim r --backend:cpp tests/tbigints.nim"
exec "nim r --backend:cpp tests/tbugs.nim"
for backend in ["c", "cpp"]:
echo "testing " & backend & " backend"
for file in ["tbigints.nim", "tbugs.nim"]:
exec "nim r --hints:off --backend:" & backend & " tests/" & file
2 changes: 1 addition & 1 deletion src/bigints.nim
Original file line number Diff line number Diff line change
Expand Up @@ -758,7 +758,7 @@ proc `divmod`*(a, b: BigInt): tuple[q, r: BigInt] =

proc calcSizes(): array[2..36, int] =
for i in 2..36:
var x = i
var x = int64(i)
while x <= int64(uint32.high) + 1:
x *= i
result[i].inc
Expand Down

0 comments on commit 75b08a7

Please sign in to comment.