chore: port to zig 0.16#23
Merged
laulauland merged 6 commits intomainfrom Apr 17, 2026
Merged
Conversation
e1e1ca5 to
3f6df57
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
driftfrom Zig 0.15.2 to 0.16.0. Pure API migration, no functional changes.std.Iothrough every command and VCS callsite, adopts Juicy Main, and renames to the non-deprecatedstd.Io.Dir.path/std.mem.find*families.Io.Group/io.asyncis deferred.Changes
1.
chore: bump to zig 0.16 — mise pin, clap master, min version.mise.tomlpinningzig = "0.16.0".build.zig.zon:minimum_zig_version0.15.0 → 0.16.0.zig-claptomaster @ fc1e5cc(first 0.16-capable commit; no tagged release yet).2.
chore: port drift to zig 0.16 — plumbing (juicy main, io threading, writer/path renames)(342+/310−, 12 files)pub fn main()→pub fn main(init: std.process.Init);init.gpareplacesGeneralPurposeAllocator.CommandContextgainsio: std.Io, threaded through every command.std.fs.cwd()/openFileAbsolute/accessAbsolute→std.Io.Dir.*(takesio).std.fs.File.{stdout,stderr,stdin}→std.Io.File.*;file.close()→file.close(io).*std.io.Writer→*std.Io.Writer.std.process.Child.run→std.process.run(gpa, io, ...)withstdout_limit = .limited(N)(10 callsites invcs.zig,lint.zig).Child.init + spawn(GitCatFile) →std.process.spawn(io, ...),writeStreamingAll/readerStreaming.ArrayList(T) = .{}→.empty;trimLeft/trimRight→trimStart/trimEnd.ArrayList(u8).writer(a)→std.Io.Writer.Allocating.std.time.milliTimestamp()→std.Io.Timestamp.now(io, .real).toMilliseconds().std.fs.path.relativenow takes 5 args:(a, "", null, from, to).file.readToEndAlloc→file.reader(io, &.{}).interface.allocRemaining(a, .limited(N)).TempRepotakesstd.testing.io;Child.Termtag.Exited→.exited.3.
chore: rename to non-deprecated std.Io.Dir.path and std.mem.find*(60+/60−)std.fs.path.*→std.Io.Dir.path.*(aliased, canonical name).std.mem.indexOf*→std.mem.find*(aliased, canonical name).Testing
zig buildpasses.zig build testpasses: 63 tests, 0 failures.drift checkruns against the real drift repo and produces the expected stale-anchor output.Known issues
zig-clapis pinned tomaster @ fc1e5ccbecause upstream has not tagged a 0.16 release (latest tag 0.11.0 targets Zig 0.15.1). Bump to a tagged release when one ships.