authorgravatar for ypsvlq@gmail.comElaine Gibson <ypsvlq@gmail.com> 2026-10-13 11:11:34+01:00
committergravatar for alex@alexrp.comAlex Rønne Petersen <alex@alexrp.com> 2026-10-14 21:08:41+02:00
log02a63f88744baffacee9084544321b02289a754e
treeb1dfa6677e0c6155bd01adfa47275b22f556257f
parent3f0f63cfba14a81020902941187a166c20bfbfb7
signature Signed by SSH key SHA256:7B/LJ7bpR1eX8aCXSr4mtd5M45VMPKcx9zY8e95b5QM

Maker: fix build when Watch.have_impl is false


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

lib/compiler/Maker.zig+3-2
......@@ -841,7 +841,7 @@ pub fn main(init: process.Init.Minimal) !void {
841841 try s.serveStringMessage(.bsp_configuration, try arena.print("{f}", .{scanned_config.path}));
842842
843843 var watch: ?Watch = null;
844 defer if (watch) |*w| w.deinit();
844 defer if (Watch.have_impl) if (watch) |*w| w.deinit();
845845
846846 const Event = union(enum) {
847847 message: Reader.Error!Client.Message.Header,
......@@ -907,6 +907,7 @@ pub fn main(init: process.Init.Minimal) !void {
907907 });
908908 is_fs_watching = true;
909909 } else if (watch) |*w| {
910 if (!Watch.have_impl) unreachable;
910911 w.deinit();
911912 watch = null;
912913 }
......@@ -963,7 +964,7 @@ pub fn main(init: process.Init.Minimal) !void {
963964 if (!Watch.have_impl) fatal("--watch not yet implemented for {t}", .{native_os});
964965 break :w try .init(&maker);
965966 };
966 defer if (watch_flag) w.deinit();
967 defer if (Watch.have_impl and watch_flag) w.deinit();
967968
968969 if (web_server) |ws| try ws.updateConfiguration(&maker);
969970