makes testament.nim compiles with --experimental:strictDefs (#26037)

This commit is contained in:
Tomohiro
2026-07-25 05:32:23 +09:00
committed by GitHub
parent 99a696e0c4
commit 9bc0887755

View File

@@ -530,6 +530,7 @@ proc mmRaise(kind: TResultEnum, expected, given: string) =
raise e
proc isMetamorphicIcTest(content: string): bool =
result = false
for line in content.splitLines:
if line.strip == "#? metamorphic": return true
@@ -561,7 +562,7 @@ proc stableBinary(path: string): string =
## so two builds seconds apart differ there even with identical codegen. Skipping
## a generous fixed window keeps the clean-vs-incremental check about codegen.
const headerSkip = 4096
var f: File
var f: File = nil
if not open(f, path, fmRead):
raise newException(IOError, "cannot open: " & path)
defer: close(f)