update to zig master

This commit is contained in:
Robin Voetter
2024-05-07 23:36:49 +02:00
parent 2115516b9b
commit aa3808940e
2 changed files with 8 additions and 2 deletions

View File

@@ -226,7 +226,10 @@ pub const ShaderCompileStep = struct {
&.{ shaders_dir, &digest(&hasher) }, &.{ shaders_dir, &digest(&hasher) },
); );
try cwd.writeFile(shaders_path, shaders_file_contents.items); try cwd.writeFile(.{
.sub_path = shaders_path,
.data = shaders_file_contents.items,
});
self.generated_file.path = shaders_path; self.generated_file.path = shaders_path;
} }
}; };

View File

@@ -151,7 +151,10 @@ pub fn main() void {
}; };
} }
cwd.writeFile(out_path, formatted) catch |err| { cwd.writeFile(.{
.sub_path = out_path,
.data = formatted,
}) catch |err| {
std.log.err("failed to write to output file '{s}' ({s})", .{ out_path, @errorName(err) }); std.log.err("failed to write to output file '{s}' ({s})", .{ out_path, @errorName(err) });
std.process.exit(1); std.process.exit(1);
}; };