| ... | ... | @@ -184,8 +184,13 @@ pub fn main() anyerror!void { |
| 184 | 184 | |
| 185 | 185 | // Short circuit some of the other logic for bootstrapping. |
| 186 | 186 | if (build_options.only_c) { |
| 187 | | assert(mem.eql(u8, args[1], "build-exe")); |
| 188 | | return buildOutputType(gpa, arena, args, .{ .build = .Exe }); |
| 187 | if (mem.eql(u8, args[1], "build-exe")) { |
| 188 | return buildOutputType(gpa, arena, args, .{ .build = .Exe }); |
| 189 | } else if (mem.eql(u8, args[1], "build-obj")) { |
| 190 | return buildOutputType(gpa, arena, args, .{ .build = .Obj }); |
| 191 | } else { |
| 192 | @panic("only build-exe or build-obj is supported in a -Donly-c build"); |
| 193 | } |
| 189 | 194 | } |
| 190 | 195 | |
| 191 | 196 | return mainArgs(gpa, arena, args); |