Files
sx/tests/expected/115-post-link-callback.txt
agra 2993072972 main: "--- build done ---" delimiter on stderr for top-level #run
Tests that exercise top-level #run produce two interleaved
output streams: the interp's #run prints (flushed via
std.debug.print → stderr at core.zig:187/190) and the JIT-
executed main's prints (libc write fd=1 → stdout). When the
test runner captures both via 2>&1 the boundary between them
is invisible — the snapshot reads as one block.

Now `sx run` emits "--- build done ---\n" on stderr right
before invoking the JIT, when `hasTopLevelRun(root)` is true.
Tests without top-level #run keep their current snapshots
unchanged; only the 7 affected tests pick up the delimiter
between the build-time and run-time sections.

Example: 05-run flips from
    hello 25
    hello 25
to
    hello 25
    --- build done ---
    hello 25

— the first "hello 25" is from `#run main()` running at
compile time, the second is from JIT main() running at
runtime. The delimiter makes that explicit.

204/204 example tests + `zig build test` green.
2026-05-27 17:08:14 +03:00

3 lines
32 B
Plaintext

--- build done ---
runtime main