Commit 2f614b1a authored by take_cheeze's avatar take_cheeze

Ignore outfile check when `-c`(check syntax only) flag is enabled.

parent d3fda42e
...@@ -270,7 +270,7 @@ main(int argc, char **argv) ...@@ -270,7 +270,7 @@ main(int argc, char **argv)
fprintf(stderr, "%s: no program file given\n", args.prog); fprintf(stderr, "%s: no program file given\n", args.prog);
return EXIT_FAILURE; return EXIT_FAILURE;
} }
if (args.outfile == NULL) { if (args.outfile == NULL && !args.check_syntax) {
if (n + 1 == argc) { if (n + 1 == argc) {
args.outfile = get_outfilename(mrb, argv[n], args.initname ? C_EXT : RITEBIN_EXT); args.outfile = get_outfilename(mrb, argv[n], args.initname ? C_EXT : RITEBIN_EXT);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment