summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2025-08-01 11:27:11 -0700
committerJunio C Hamano <gitster@pobox.com>2025-08-01 11:27:11 -0700
commit152871b88b317e3c0781d2503de2b8a37bcc2146 (patch)
treed44d15ae256c7b609e018f6e74de84f2f3373294
parent23466173824c0a0f835c0d790c2f38156ae6284a (diff)
parentf31abb421ddd37e9a13e5ffc2e5c5f10f0f0f9b9 (diff)
Merge branch 'jc/do-not-scan-argv-without-parsing'
Update a hard-to-read in-code NEEDSWORK comment. * jc/do-not-scan-argv-without-parsing: rev-list: update a NEEDSWORK comment
-rw-r--r--builtin/rev-list.c22
1 files changed, 13 insertions, 9 deletions
diff --git a/builtin/rev-list.c b/builtin/rev-list.c
index 1d084bcac3..97a3af36ec 100644
--- a/builtin/rev-list.c
+++ b/builtin/rev-list.c
@@ -660,17 +660,21 @@ int cmd_rev_list(int argc,
*
* Let "--missing" to conditionally set fetch_if_missing.
*/
+
/*
- * NEEDSWORK: These loops that attempt to find presence of
- * options without understanding that the options they are
- * skipping are broken (e.g., it would not know "--grep
+ * NEEDSWORK: The next loop is utterly broken. It tries to
+ * notice an option is used, but without understanding if each
+ * option takes an argument, which fundamentally would not
+ * work. It would not know "--grep
* --exclude-promisor-objects" is not triggering
- * "--exclude-promisor-objects" option). We really need
- * setup_revisions() to have a mechanism to allow and disallow
- * some sets of options for different commands (like rev-list,
- * replay, etc). Such a mechanism should do an early parsing
- * of options and be able to manage the `--missing=...` and
- * `--exclude-promisor-objects` options below.
+ * "--exclude-promisor-objects" option, for example.
+ *
+ * We really need setup_revisions() to have a mechanism to
+ * allow and disallow some sets of options for different
+ * commands (like rev-list, replay, etc). Such a mechanism
+ * should do an early parsing of options and be able to manage
+ * the `--missing=...` and `--exclude-promisor-objects`
+ * options below.
*/
for (i = 1; i < argc; i++) {
const char *arg = argv[i];