docs: update Zig 0.16.0 as stable and fix benchmark timing#24
docs: update Zig 0.16.0 as stable and fix benchmark timing#24jinzhongjia merged 1 commit into016from
Conversation
There was a problem hiding this comment.
Code Review
This pull request updates the library's documentation and benchmarking logic to support Zig 0.16.0. The changes include updating version support tables in AGENT.md, README.md, and README_CN.md, as well as adapting the benchmarking timer in src/bench.zig to use the new std.Io APIs. Review feedback suggests that the usage of std.Io as a type and the specific API path for std.Io.Clock.awake may be incorrect, as std.Io is typically a namespace in the Zig standard library.
I am having trouble creating individual review comments. Click here to see my feedback.
src/bench.zig (21)
The type ?std.Io is likely invalid because std.Io is a namespace, not a type. If you intended to use a specific type from the std.io namespace, please correct the type definition. If std.Io is meant to be a custom type, ensure it is properly defined.
src/bench.zig (28)
The usage of std.Io.Clock.awake appears to be incorrect if std.Io is a namespace. Please verify the API path for accessing the clock in Zig 0.16+.
Summary
Update documentation and benchmark implementation to reflect Zig 0.16.0 as a stable release, replacing the previous nightly/dev references.
Changes
src/bench.zigto usestd.Io.Clock.awakefor timing in Zig 0.16+BenchRuntimestruct to hold the requiredstd.IocontextgetTimeNs()to use the stable Zig 0.16 APINotes
All changes maintain backward compatibility with Zig 0.14.x and 0.15.x versions.