shared/options: convert mode boolean to an enum

This will make it easier to add new modes of operation later.
But I'm happy with how this came out — I think the mode setting
is nicer to read then the old bool.
This commit is contained in:
Zbigniew Jędrzejewski-Szmek
2026-04-16 09:05:01 +02:00
parent 961e92854a
commit 6133fc0e1c
6 changed files with 63 additions and 52 deletions
+1 -1
View File
@@ -586,7 +586,7 @@ static int parse_argv(int argc, char *argv[]) {
assert(argc >= 0);
assert(argv);
OptionParser state = { argc, argv, /* stop_at_first_nonoption= */ true };
OptionParser state = { argc, argv, OPTION_PARSER_STOP_AT_FIRST_NONOPTION };
const Option *opt;
const char *arg;