Thread (34 messages) 34 messages, 3 authors, 2025-10-30

Re: [PATCH 5/8] builtin/pack-objects: simplify logic to find kept or nonlocal objects

From: Taylor Blau <hidden>
Date: 2025-10-29 23:15:04

On Wed, Oct 29, 2025 at 03:55:17PM +0100, Toon Claes wrote:
quoted
+		/*
+		 * We have already checked `last_found`, so there is no need to
+		 * re-check here.
+		 */
I had to reason with myself why you need to extra `(void *)1` check,
maybe you can extend the comment a bit:

		/*
		 * When `last_found` was set to something else then
		 * `(void *)1` we have already checked it,
		 * so there is no need to re-check here.
		 */
quoted
+		if (p == last_found && last_found != (void *)1)
+			continue;
I wrote above to Patrick that I think the "&& last_found != (void *)1"
part can be dropped, since repo_for_each_pack() should never hand us
such a pointer to begin with.

Thanks,
Taylor
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help