authorgravatar for info@bnoordhuis.nlBen Noordhuis <info@bnoordhuis.nl> 2018-06-29 23:28:42+02:00
committergravatar for info@bnoordhuis.nlBen Noordhuis <info@bnoordhuis.nl> 2018-06-29 23:32:10+02:00
log03f66825d6b6922da250cdb99c2996455541e0f9
tree43d1cf7b4ba7d0215f5ddb7f943dcfc50f6a9434
parentf1c56f7f225f2f3054abd8c9e6330a0f1e20b2a6

support --emit in 'test' command

Support the `--emit` switch in `zig --emit asm test file.zig`. The command fails because no tests run (no executable is created) but it emits the requested file. That seems like a good tradeoff.

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

src/main.cpp+2
......@@ -924,6 +924,8 @@ int main(int argc, char **argv) {
924924 codegen_print_timing_report(g, stdout);
925925 return EXIT_SUCCESS;
926926 } else if (cmd == CmdTest) {
927 codegen_set_emit_file_type(g, emit_file_type);
928
927929 ZigTarget native;
928930 get_native_target(&native);
929931