build: update to Zig 0.12

(cherry picked from commit 033cad47bf)
This commit is contained in:
Isaac Freund
2024-03-07 16:19:22 +01:00
parent c757e1b33e
commit 312465e0cb
51 changed files with 285 additions and 271 deletions

View File

@ -740,7 +740,7 @@ fn commitTransaction(root: *Root) void {
// We need this listener to deal with outputs that have their position auto-configured
// by the wlr_output_layout.
fn handleLayoutChange(listener: *wl.Listener(*wlr.OutputLayout), _: *wlr.OutputLayout) void {
const root = @fieldParentPtr(Root, "layout_change", listener);
const root: *Root = @fieldParentPtr("layout_change", listener);
root.handleOutputConfigChange() catch std.log.err("out of memory", .{});
}
@ -775,7 +775,7 @@ fn handleManagerApply(
listener: *wl.Listener(*wlr.OutputConfigurationV1),
config: *wlr.OutputConfigurationV1,
) void {
const root = @fieldParentPtr(Root, "manager_apply", listener);
const root: *Root = @fieldParentPtr("manager_apply", listener);
defer config.destroy();
std.log.scoped(.output_manager).info("applying output configuration", .{});
@ -789,7 +789,7 @@ fn handleManagerTest(
listener: *wl.Listener(*wlr.OutputConfigurationV1),
config: *wlr.OutputConfigurationV1,
) void {
const root = @fieldParentPtr(Root, "manager_test", listener);
const root: *Root = @fieldParentPtr("manager_test", listener);
defer config.destroy();
root.processOutputConfig(config, .test_only);