git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] merge-ort: fix bug with renormalization and rename/delete conflicts

From
Junio C Hamano <gitster@pobox.com>
Date
Dec 30, 2021, 22:56 UTC
Message-ID
<xmqqa6ghog5x.fsf@gitster.g>
In-Reply-To
<78ba0d99-246b-d90c-b725-c084c8304f02@gmail.com>
Derrick Stolee <stolee@gmail.com> writes:
Show 7 quoted lines
> This breakdown of the cases is informative, and I like how self-contained
> the change is.
>  ....
>
> This patch looks good to me. Thanks!
>
> Reviewed-by: Derrick Stolee <dstolee@microsoft.com>
Thanks, both.

A related tangent, but I was looking at the data structure involved and noticed that the casting between structure types "merged_info" and "conflict_info" looked a bit ugly. It might be worth cleaning them up into

 (A) a union with two struct, with "clean" member in the union to
     switch between the two structures; or
 (B) a single structure that looks like "conflict_info" but inlines
     members of "merged_info" into it.

The latter may be cleaner and simpler, and the unified data type would be the "merge info", which may be representing cleanly merged path, or conflicted path, and would justify conditional use of some members based on the value of the .clean member.

Previous: Derrick StoleeNext: Elijah Newren
Message 3 of 5 in “merge-ort: fix bug with renormalization and rename/delete conflicts”
  1. merge-ort: fix bug with renormalization and rename/delete conflictsElijah Newren via GitGitGadget, Dec 28, 2021
  2. Derrick StoleeDec 28, 2021
  3. Junio C HamanoDec 30, 2021
  4. Elijah NewrenDec 30, 2021
  5. merge-ort: fix bug with renormalization and rename/delete conflictsElijah Newren via GitGitGadget, Dec 30, 2021

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.