summaryrefslogtreecommitdiff
path: root/merge-recursive.h
diff options
context:
space:
mode:
authorElijah Newren <newren@gmail.com>2020-08-02 03:14:27 (GMT)
committerJunio C Hamano <gitster@pobox.com>2020-08-02 18:03:57 (GMT)
commit56e743426b183d8aea8f4caa363e7f3c7da27278 (patch)
treee06beda6ab86dd1c9bf913c1acfeb6099e48c37a /merge-recursive.h
parentb3d7a52fac39193503a0b6728771d1bf6a161464 (diff)
downloadgit-56e743426b183d8aea8f4caa363e7f3c7da27278.zip
git-56e743426b183d8aea8f4caa363e7f3c7da27278.tar.gz
git-56e743426b183d8aea8f4caa363e7f3c7da27278.tar.bz2
merge-recursive: fix unclear and outright wrong comments
Commits 7c0a6c8e47 ("merge-recursive: move some definitions around to clean up the header", 2019-08-17), and b4db8a2b76 ("merge-recursive: remove useless parameter in merge_trees()", 2019-08-17) added some useful documentation to the functions, but had a few places where the new comments were unclear or even misleading. Fix those comments. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'merge-recursive.h')
-rw-r--r--merge-recursive.h13
1 files changed, 6 insertions, 7 deletions
diff --git a/merge-recursive.h b/merge-recursive.h
index 978847e..0795a1d 100644
--- a/merge-recursive.h
+++ b/merge-recursive.h
@@ -69,9 +69,8 @@ int parse_merge_opt(struct merge_options *opt, const char *s);
*
* Outputs:
* - See RETURN VALUES above
- * - No commit is created
* - opt->repo->index has the new index
- * - $GIT_INDEX_FILE is not updated
+ * - new index NOT written to disk
* - The working tree is updated with results of the merge
*/
int merge_trees(struct merge_options *opt,
@@ -81,7 +80,7 @@ int merge_trees(struct merge_options *opt,
/*
* merge_recursive is like merge_trees() but with recursive ancestor
- * consolidation and, if the commit is clean, creation of a commit.
+ * consolidation.
*
* NOTE: empirically, about a decade ago it was determined that with more
* than two merge bases, optimal behavior was found when the
@@ -91,9 +90,9 @@ int merge_trees(struct merge_options *opt,
*
* Outputs:
* - See RETURN VALUES above
- * - If merge is clean, a commit is created and its address written to *result
+ * - *result is treated as scratch space for temporary recursive merges
* - opt->repo->index has the new index
- * - $GIT_INDEX_FILE is not updated
+ * - new index NOT written to disk
* - The working tree is updated with results of the merge
*/
int merge_recursive(struct merge_options *opt,
@@ -109,9 +108,9 @@ int merge_recursive(struct merge_options *opt,
*
* Outputs:
* - See RETURN VALUES above
- * - If merge is clean, a commit is created and its address written to *result
+ * - *result is treated as scratch space for temporary recursive merges
* - opt->repo->index has the new index
- * - $GIT_INDEX_FILE is updated
+ * - new index also written to $GIT_INDEX_FILE on disk
* - The working tree is updated with results of the merge
*/
int merge_recursive_generic(struct merge_options *opt,