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

Re: [PATCH 2/2] xdiff: implement empty line chunk heuristic

From
Jacob Keller <jacob.keller@gmail.com>
Date
Apr 15, 2016, 23:32 UTC
Message-ID
<CA+P7+xoMVzYwWv3=7hTUM7gMjm4i7Vv74aoyw17T_CbToZTVaA@mail.gmail.com>
In-Reply-To
<CA+P7+xq-njse8TKWExwKWx=6ynVNwM1ODHnTij6pdQNejvKT=g@mail.gmail.com>
On Fri, Apr 15, 2016 at 4:05 PM, Jacob Keller <jacob.keller@gmail.com> wrote:
Show 8 quoted lines
> There's a few places that will need cleaning up (comments and such)
> that mention empty line still, but that's not surprising. I am going
> to test this for a bit on my local repos, and see if it makes any
> difference to the old heuristic as well.
>
> Thanks,
> Jake
>

I ran this heuristic on git.git and it produces tons of false positive transforms which are much lease readable (to me at least), far more than those produced by the newline/blank link heuristic did.

I think we should stick with the empty line heuristic instead of this version, even if it's easier to implement this version.

We still would need to figure out how to handle CRLF properly but it's worth resolving that than this heuristic is.

Thanks, Jake

Previous: Jacob KellerNext: Stefan Beller
Message 5 of 11 in “implement shortest line diff chunk heuristic”
  1. 0/2 implement shortest line diff chunk heuristicStefan Beller, Apr 15, 2016
  2. 1/2 xdiff: add recs_match helper functionStefan Beller, Apr 15, 2016
  3. 2/2 xdiff: implement empty line chunk heuristicStefan Beller, Apr 15, 2016
  4. Jacob KellerApr 15, 2016
  5. Jacob KellerApr 15, 2016
  6. Stefan BellerApr 15, 2016
  7. Junio C HamanoApr 16, 2016
  8. Stefan BellerApr 16, 2016
  9. Jacob KellerApr 16, 2016
  10. Junio C HamanoApr 18, 2016
  11. Stefan BellerApr 18, 2016

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.