Re: [PATCH 1/4] merge-ort: barebones API of new merge strategy with empty implementation
- From
- Peter Baumann <peter.baumann@gmail.com>
- Date
- Oct 24, 2020, 10:46 UTC
- Message-ID
- <CAJm9OHcEGfkgEsTZhD4qKG9Ns5fu=COToWz0XkHhPuJ_DtGzgA@mail.gmail.com>
- In-Reply-To
- <54ef18182cf3a4b5d02889c139e495fa68588652.1603286555.git.gitgitgadget@gmail.com>
Am Do., 22. Okt. 2020 um 03:28 Uhr schrieb Elijah Newren via GitGitGadget <gitgitgadget@gmail.com>: [... snipping a lot of unneeded context ...]
Show 30 quoted lines
> diff --git a/merge-ort.h b/merge-ort.h
> new file mode 100644
> index 0000000000..9c655cd3ad
> --- /dev/null
> +++ b/merge-ort.h
> @@ -0,0 +1,49 @@
> +#ifndef MERGE_ORT_H
> +#define MERGE_ORT_H
> +
> +#include "merge-recursive.h"
> +
> +struct commit;
> +struct tree;
> +
> +struct merge_result {
> + /* whether the merge is clean */
> + int clean;
> +
> + /* Result of merge. If !clean, represents what would go in worktree */
> + struct tree *tree;
> +
> + /*
> + * Additional metadata used by merge_switch_to_result() or future calls
> + * to merge_inmemory_*().
> + */
> + unsigned _;
> + void *priv;
> +};
> +
> +/* rename-detecting three-way merge, no recursion. */^^^^^^^^^^^^^
> +void merge_inmemory_recursive(struct merge_options *opt,
^^^^^^^^^
Show 6 quoted lines
> + struct commit_list *merge_bases, > + struct commit *side1, > + struct commit *side2, > + struct merge_result *result); > + > +/* rename-detecting three-way merge with recursive ancestor consolidation. */
^^^^^^^^^^^^^
> +void merge_inmemory_nonrecursive(struct merge_options *opt,
^^^^^^^^^^^^
Show 5 quoted lines
> + struct tree *merge_base, > + struct tree *side1, > + struct tree *side2, > + struct merge_result *result); > +
The comments don't fit to the actually method name. I assume they should be switched?
-Peter