Conversation
This migrates the entire codebase from Zig 0.14.1 to Zig 0.15.2. Key API changes: - Remove `usingnamespace` (removed from the language) — all mixins now use explicit re-export of each declaration - `ArrayList.init(allocator)` → `.empty` + pass allocator to each method call (deinit, append, appendSlice, etc.) - `callconv(.C)` → `callconv(.c)` (lowercase enum literals) - `std.os.windows.WINAPI` → `std.builtin.CallingConvention.winapi` - `std.fmt.allocPrintZ` → `std.fmt.allocPrintSentinel` - `std.atomic.Atomic` → `std.atomic.Value` - `std.sort.sort` → `std.mem.sort` - `std.time.sleep` → `std.Thread.sleep` - `SinglyLinkedList` became intrusive (compat wrapper added in data.zig) - `BoundedArray` removed (compat replacement in containers.zig) - `anyframe` removed (async.zig stubbed) - `std.Uri.path` API changes (toRaw signature) - format function signatures changed - zigimg StreamSource → ReadStream API Also updates: - vendor/zigwin32 for 0.15.2 compatibility - build.zig / build_capy.zig for 0.15.2 build API - build.zig.zon dependency hashes (zig-objc, zigimg) - flake.nix / flake.lock for Zig 0.15.2 toolchain All 28 examples compile successfully on both x86_64-windows-gnu (cross-compile) and native macOS (aarch64-macos).
|
I'm newish to Zig, and I'm finding that Zig upgrade PR's are beasts. (Ghostty apparently had a ton of required updates, too.) It's possible that you might not want to go through this pain again for 0.16 and will want to wait for that (likely this year) to drop. If you want, we can just leave this open as the "comprehensive upgrade PR" and just update it for 0.16 when that's appropriate. |
|
A more general thing is that the |
|
ah, makes sense, then you get the upstream whenever you update. will rejigger it |
Summary
This migrates the entire codebase from Zig 0.14.1 to Zig 0.15.2. No new features or behavioral changes — this is purely a language/API migration.
This is the first of several focused PRs that replace the monolithic #121 (which the maintainer correctly identified as too large to review).
Key API changes
usingnamespaceremoval — replaced with explicit re-exports for every mixin declaration throughout components, backends, and examplesArrayListAPI —.init(allocator)→.empty+ pass allocator to each method callcallconv(.C)→callconv(.c)(lowercase enum literals)std.os.windows.WINAPI→std.builtin.CallingConvention.winapistd.fmt.allocPrintZ→std.fmt.allocPrintSentinelstd.atomic.Atomic→std.atomic.Valuestd.sort.sort→std.mem.sortstd.time.sleep→std.Thread.sleepSinglyLinkedListbecame intrusive (compat wrapper added),BoundedArrayremoved (replacement added)anyframeremoved (async.zigstubbed since the async subsystem was already incomplete)std.Uri.path.toRawsignature changedStreamSource→ReadStreamAPITest plan
x86_64-windows-gnu(cross-compile)