authorgravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2026-10-17 12:47:45-07:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2026-10-17 12:47:45-07:00
log722aa2a8ab4aeac4f47d79569d5d0d73406fa0f2
tree56da4c28ca179878475e0c557bda2d29180dc00b
parent21141cb88a130fb113f8c17647bae34ae74efa05

Revert "build.zig: enable debug extensions if optimize is null"

This reverts commit 40fd34fe7bd7b5c3fdbc2804f7b39bdf02d09aff. This should have been included also in previous commit.

1 files changed, 2 insertions(+), 2 deletions(-)

build.zig+2-2
......@@ -206,7 +206,7 @@ pub fn build(b: *std.Build) !void {
206206
207207 const mem_leak_frames: u32 = b.option(u32, "mem-leak-frames", "How many stack frames to print when a memory leak occurs. Tests get 2x this amount.") orelse blk: {
208208 if (strip == true) break :blk @as(u32, 0);
209 if (optimize) |opt| if (opt != .debug) break :blk 0;
209 if (optimize != .debug) break :blk 0;
210210 break :blk 4;
211211 };
212212
......@@ -255,7 +255,7 @@ pub fn build(b: *std.Build) !void {
255255 exe.root_module.link_libc = true;
256256 }
257257
258 const is_debug = if (optimize) |opt| opt == .debug else true;
258 const is_debug = optimize == .debug;
259259 const enable_debug_extensions = b.option(bool, "debug-extensions", "Enable commands and options useful for debugging the compiler") orelse is_debug;
260260 const enable_logging = b.option(bool, "log", "Enable debug logging with --debug-log") orelse is_debug;
261261