authorgravatar for ypsvlq@gmail.comElaine Gibson <ypsvlq@gmail.com> 2026-05-20 12:04:36+01:00
committergravatar for alex@alexrp.comAlex Rønne Petersen <alex@alexrp.com> 2026-05-28 04:56:12+02:00
log8d1b6e339750a37207bdaa8b5e9b4bda8d330fec
tree81a16dbfb55ab8583853a7baae9b3e360d7fd8ef
parentf04799dc9c60189b11f0bbcd4f0027b9928ef6e4

compiler: fix spirv makeWritable


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

src/link.zig+2-3
...@@ -660,13 +660,12 @@ pub const File = struct {...@@ -660,13 +660,12 @@ pub const File = struct {
660 base.file = mf.memory_map.file;660 base.file = mf.memory_map.file;
661 try mf.ensureTotalCapacity(@intCast(mf.nodes.items[0].location().resolve(mf)[1]));661 try mf.ensureTotalCapacity(@intCast(mf.nodes.items[0].location().resolve(mf)[1]));
662 },662 },
663 .c => if (base.file == null) {663 .c, .spirv => if (base.file == null) {
664 dev.check(.c_linker);664 dev.checkAny(&.{ .c_linker, .spirv_linker });
665 base.file = try base.emit.root_dir.handle.openFile(io, base.emit.sub_path, .{665 base.file = try base.emit.root_dir.handle.openFile(io, base.emit.sub_path, .{
666 .mode = .write_only,666 .mode = .write_only,
667 });667 });
668 },668 },
669 .spirv => dev.check(.spirv_linker),
670 .plan9 => unreachable,669 .plan9 => unreachable,
671 }670 }
672 }671 }