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 20:49:25+02:00
logd8938120130dbe48ee8764b502b18c6224ab9340
tree111d04921ca85fe29331c7362d92e565827d0a72
parent58ab2093d423a59c5e02ebd38cc917d351395342

Maker: fix build when Watch.have_impl is false


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

lib/compiler/Maker.zig+3-2
......@@ -871,7 +871,7 @@ pub fn main(init: process.Init.Minimal) !void {
871871 try s.serveStringMessage(.bsp_configuration, try arena.print("{f}", .{scanned_config.path}));
872872
873873 var watch: ?Watch = null;
874 defer if (watch) |*w| w.deinit();
874 defer if (Watch.have_impl) if (watch) |*w| w.deinit();
875875
876876 const Event = union(enum) {
877877 message: Reader.Error!Client.Message.Header,
......@@ -937,6 +937,7 @@ pub fn main(init: process.Init.Minimal) !void {
937937 });
938938 is_fs_watching = true;
939939 } else if (watch) |*w| {
940 if (!Watch.have_impl) unreachable;
940941 w.deinit();
941942 watch = null;
942943 }
......@@ -993,7 +994,7 @@ pub fn main(init: process.Init.Minimal) !void {
993994 if (!Watch.have_impl) fatal("--watch not yet implemented for {t}", .{native_os});
994995 break :w try .init(&maker);
995996 };
996 defer if (watch_flag) w.deinit();
997 defer if (Watch.have_impl and watch_flag) w.deinit();
997998
998999 if (web_server) |ws| try ws.updateConfiguration(&maker);
9991000