diff options
| author | Andrew Kelley <andrew@ziglang.org> | 2023-03-14 16:12:24 -0700 |
|---|---|---|
| committer | Andrew Kelley <andrew@ziglang.org> | 2023-03-15 10:48:15 -0700 |
| commit | 363d4a107de3af95620f82e851e8777aa9f576c9 (patch) | |
| tree | 14a7536caf8366329f0f2f9286fa539d0fab3db2 /src/Compilation.zig | |
| parent | ed33901218363b9d1baee4c37e85f573dc034e06 (diff) | |
| download | zig-363d4a107de3af95620f82e851e8777aa9f576c9.tar.gz zig-363d4a107de3af95620f82e851e8777aa9f576c9.zip | |
add compile log output to build runner
Diffstat (limited to 'src/Compilation.zig')
| -rw-r--r-- | src/Compilation.zig | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/src/Compilation.zig b/src/Compilation.zig index ec21d2c483..89512ce744 100644 --- a/src/Compilation.zig +++ b/src/Compilation.zig @@ -2705,7 +2705,8 @@ pub fn getAllErrorsAlloc(self: *Compilation) !ErrorBundle { assert(self.totalErrorCount() == bundle.root_list.items.len); - return bundle.toOwnedBundle(); + const compile_log_text = if (self.bin_file.options.module) |m| m.compile_log_text.items else ""; + return bundle.toOwnedBundle(compile_log_text); } pub const ErrorNoteHashContext = struct { @@ -2954,11 +2955,6 @@ pub fn addZirErrorMessages(eb: *ErrorBundle.Wip, file: *Module.File) !void { } } -pub fn getCompileLogOutput(self: *Compilation) []const u8 { - const module = self.bin_file.options.module orelse return &[0]u8{}; - return module.compile_log_text.items; -} - pub fn performAllTheWork( comp: *Compilation, main_progress_node: *std.Progress.Node, |
