diff --git a/lib/compiler/Maker/Step/Compile.zig b/lib/compiler/Maker/Step/Compile.zig index 75814a1e7bfdae19a12d6279978a6e6523a046ff..0b66dc282c801cd3cabff5c0a72e69cb36aab0c2 100644 --- a/lib/compiler/Maker/Step/Compile.zig +++ b/lib/compiler/Maker/Step/Compile.zig @@ -991,8 +991,9 @@ fn checkCompileErrors(arena: Allocator, maker: *Maker, step_index: Configuration const conf_comp = conf_step.extended.get(conf.extra).compile; // Clear this field so that it does not get printed by the build runner. - const actual_eb = step.result_error_bundle; + var actual_eb = step.result_error_bundle; step.result_error_bundle = .empty; + defer actual_eb.deinit(maker.gpa); const actual_errors = ae: { var aw: std.Io.Writer.Allocating = .init(arena);