summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2019-09-09 19:26:38 (GMT)
committerJunio C Hamano <gitster@pobox.com>2019-09-09 19:26:38 (GMT)
commit4c49dd042d34a44b3238ea901aeceeea716ab8e2 (patch)
tree35131d2feb8a2a31705d3c67e120f30fd0e5db3c
parentd8b1ce79729b1744727c29ec818c34ec43ee9599 (diff)
parent19800bdc3f35fd0d0ab1bcef4dfa9ac69968288f (diff)
downloadgit-4c49dd042d34a44b3238ea901aeceeea716ab8e2.zip
git-4c49dd042d34a44b3238ea901aeceeea716ab8e2.tar.gz
git-4c49dd042d34a44b3238ea901aeceeea716ab8e2.tar.bz2
Merge branch 'nd/diff-parseopt'
Compilation fix. * nd/diff-parseopt: parseopt: move definition of enum parse_opt_result up
-rw-r--r--parse-options.h18
1 files changed, 9 insertions, 9 deletions
diff --git a/parse-options.h b/parse-options.h
index a4bd40b..38a33a0 100644
--- a/parse-options.h
+++ b/parse-options.h
@@ -46,6 +46,15 @@ enum parse_opt_option_flags {
PARSE_OPT_COMP_ARG = 1024
};
+enum parse_opt_result {
+ PARSE_OPT_COMPLETE = -3,
+ PARSE_OPT_HELP = -2,
+ PARSE_OPT_ERROR = -1, /* must be the same as error() */
+ PARSE_OPT_DONE = 0, /* fixed so that "return 0" works */
+ PARSE_OPT_NON_OPTION,
+ PARSE_OPT_UNKNOWN
+};
+
struct option;
typedef int parse_opt_cb(const struct option *, const char *arg, int unset);
@@ -241,15 +250,6 @@ const char *optname(const struct option *opt, int flags);
/*----- incremental advanced APIs -----*/
-enum parse_opt_result {
- PARSE_OPT_COMPLETE = -3,
- PARSE_OPT_HELP = -2,
- PARSE_OPT_ERROR = -1, /* must be the same as error() */
- PARSE_OPT_DONE = 0, /* fixed so that "return 0" works */
- PARSE_OPT_NON_OPTION,
- PARSE_OPT_UNKNOWN
-};
-
/*
* It's okay for the caller to consume argv/argc in the usual way.
* Other fields of that structure are private to parse-options and should not