Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJonathan Tan <jonathantanmy@google.com>2021-09-09 21:47:29 +0300
committerJunio C Hamano <gitster@pobox.com>2021-09-10 00:09:30 +0300
commit10a0d6ae64ad4fec12ab2c1ed13d1791dde60371 (patch)
tree77babd696d3936864bdb6d5e4f1849926438a478 /revision.h
parent8eb8dcf94643ca6e7c3f040f3e0bf96e11c7ae47 (diff)
revision: remove "submodule" from opt struct
Clean up a TODO in revision.h by removing the "submodule" field from struct setup_revision_opt. This field is only used to specify the ref store to use, so use rev_info->repo to determine the ref store instead. The only users of this field are merge-ort.c and merge-recursive.c. However, both these files specify the superproject as rev_info->repo and the submodule as setup_revision_opt->submodule. In order to be able to pass the submodule as rev_info->repo, all commits must be parsed with the submodule explicitly specified; this patch does that as well. (An incremental solution in which only some commits are parsed with explicit submodule will not work, because if the same commit is parsed twice in different repositories, there will be 2 heap-allocated object structs corresponding to that commit, and any flag set by the revision walking mechanism on one of them will not be reflected onto the other.) Signed-off-by: Jonathan Tan <jonathantanmy@google.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'revision.h')
-rw-r--r--revision.h1
1 files changed, 0 insertions, 1 deletions
diff --git a/revision.h b/revision.h
index fbb068da9f..d8e0e93026 100644
--- a/revision.h
+++ b/revision.h
@@ -339,7 +339,6 @@ extern volatile show_early_output_fn_t show_early_output;
struct setup_revision_opt {
const char *def;
void (*tweak)(struct rev_info *, struct setup_revision_opt *);
- const char *submodule; /* TODO: drop this and use rev_info->repo */
unsigned int assume_dashdash:1,
allow_exclude_promisor_objects:1;
unsigned revarg_opt;