diff --git a/lib/compiler/Maker/Step.zig b/lib/compiler/Maker/Step.zig index 783e3ea2f4ad267fddfa14aae27cfed61fc0acd8..8496548b7a8970292533c1fca07ff58cc2b265aa 100644 --- a/lib/compiler/Maker/Step.zig +++ b/lib/compiler/Maker/Step.zig @@ -321,7 +321,6 @@ pub fn deinit(step: *Step, gpa: Allocator) void { .config_header, .fail, .find_program, - .fmt, .install_artifact, .install_dir, .install_file, @@ -332,7 +331,7 @@ pub fn deinit(step: *Step, gpa: Allocator) void { .update_source_files, .write_file, => {}, - .run => |*extended| extended.deinit(gpa), + inline .fmt, .run => |*extended| extended.deinit(gpa), } step.* = undefined; } diff --git a/lib/compiler/Maker/Step/Fmt.zig b/lib/compiler/Maker/Step/Fmt.zig index ef54df4fdc5c06942b4b8943f26bf01b7587cc59..72267c6e9fedeef3707e5e14b681c87d7636bf4e 100644 --- a/lib/compiler/Maker/Step/Fmt.zig +++ b/lib/compiler/Maker/Step/Fmt.zig @@ -63,3 +63,7 @@ pub fn make( }; try step.handleChildProcessTerm(maker, run_result.term); } + +pub fn deinit(fmt: *Fmt, gpa: std.mem.Allocator) void { + fmt.argv.deinit(gpa); +}