| ... | ... | @@ -1269,6 +1269,10 @@ fn buildOutputType( |
| 1269 | 1269 | fatal("one zig source file is required to run `zig test`", .{}); |
| 1270 | 1270 | } |
| 1271 | 1271 | |
| 1272 | if (link_objects.items.len == 0 and root_src_file == null and c_source_files.items.len == 0 and arg_mode == .run) { |
| 1273 | fatal("one source file is required to run `zig run`", .{}); |
| 1274 | } |
| 1275 | |
| 1272 | 1276 | const root_name = if (provided_name) |n| n else blk: { |
| 1273 | 1277 | if (arg_mode == .zig_test) { |
| 1274 | 1278 | break :blk "test"; |