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

Re: [PATCH] terminology tweak: prune -> path limiting

From
Junio C Hamano <gitster@pobox.com>
Date
Dec 11, 2018, 01:40 UTC
Message-ID
<xmqq1s6oon7a.fsf@gitster-ct.c.googlers.com>
In-Reply-To
<CAMfpvhKh3xewUY-g9oVJq1o=G3w9EspoQUHc1edHUx3AD4OWfg@mail.gmail.com>
Matthew DeVore <matvore@google.com> writes:
> When I tried to figure out what "prune" and "prune_data" ("data" is
> quite vague, so these two fields read like "prune_1" and "prune_2")
> referred to in "revision.h",...

It was unfortunate that 8efdc326 ("rev-lib: Make it easy to do rename tracking (take 2)", 2006-03-10) had to rename "paths" to "prune_data" when attempting to generalize the history simplification mechanism by introducing "prune_fn", which can be used instead of a fixed function, and as one half of the pair, "data used by the prune function" made some sense.

When we partially reverted that over-generalization with 53b2c823 ("revision walker: mini clean-up", 2007-11-05), we probably should have changed the prune_data back to paths, but we didn't. Worse yet, when we made prune_data from a void pointer to struct pathspec at afe069d1 ("struct rev_info: convert prune_data to struct pathspec", 2010-12-17), we really should have renamed it back to paths, but we didn't.

So I think it is a good idea to get rid of prune_data and make it clear it is no longer a generic thing but cannot be anything but a pathspec. I am not sure what the bit should be called, though. It is a bit to enable any history simplification and not limited to pathspec limiting (e.g. simplify-by-decoration enables it, too).

Previous: Matthew DeVoreNext: MATTHEW DEVORE
Message 5 of 6 in “terminology tweak: prune -> path limiting”
  1. terminology tweak: prune -> path limitingMatthew DeVore, Dec 6, 2018
  2. Junio C HamanoDec 9, 2018
  3. Junio C HamanoDec 9, 2018
  4. Matthew DeVoreDec 10, 2018
  5. Junio C HamanoDec 11, 2018
  6. MATTHEW DEVOREDec 11, 2018

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.