Manuscript Documentation
v2026.12.0

@std/test/bench.ms#

Import each required symbol with import Name from "@std/test/bench.ms".

run_bench_block Function#

Called by the entry that ms bench builds, with each block’s body; programs do not call it. The body is one iteration to repeat and time.

Manuscript
fn run_bench_block(body fn() Result[Void, Error], operations Int) Result[Void, Error] { ... }

run_bench_fixture Function#

Called by the entry that ms bench builds for a file with a make_fixture, with each block’s body, which takes the file’s fixture; programs do not call it. The fixture is made, and before_all and before_each have run, before the timing starts, and after_each and after_all run after it.

Manuscript
fn run_bench_fixture[F](body fn(var F) Result[Void, Error], operations Int, var state F) Result[Void, Error] { ... }