update all occurrences of close() to close(io)

This commit is contained in:
Andrew Kelley
2025-12-05 19:08:37 -08:00
parent eab354b2f5
commit aafddc2ea1
75 changed files with 1014 additions and 707 deletions
+2 -2
View File
@@ -152,7 +152,7 @@ fn cmdObjCopy(gpa: Allocator, arena: Allocator, args: []const []const u8) !void
const io = threaded.io();
const input_file = fs.cwd().openFile(input, .{}) catch |err| fatal("failed to open {s}: {t}", .{ input, err });
defer input_file.close();
defer input_file.close(io);
const stat = input_file.stat() catch |err| fatal("failed to stat {s}: {t}", .{ input, err });
@@ -180,7 +180,7 @@ fn cmdObjCopy(gpa: Allocator, arena: Allocator, args: []const []const u8) !void
const mode = if (out_fmt != .elf or only_keep_debug) fs.File.default_mode else stat.mode;
var output_file = try fs.cwd().createFile(output, .{ .mode = mode });
defer output_file.close();
defer output_file.close(io);
var out = output_file.writer(&output_buffer);