]> git.ipfire.org Git - thirdparty/git.git/commit
reftable/iter: drop double-checking logic
authorPatrick Steinhardt <ps@pks.im>
Thu, 22 Aug 2024 06:34:54 +0000 (08:34 +0200)
committerJunio C Hamano <gitster@pobox.com>
Thu, 22 Aug 2024 14:59:46 +0000 (07:59 -0700)
commitb34ce7e911e315390b64f565accc6ca79e85443a
tree73c51a8cbe75f1abdb9ca8325b17f8a34b7d685f
parentaef860265365052bd0a2aac4cc618be22446fc9d
reftable/iter: drop double-checking logic

The filtering ref iterator can be used to only yield refs which are not
in a specific skip list. This iterator has an option to double-check the
results it returns, which causes us to seek the reference we are about
to yield via a separate table such that we detect whether the reference
that the first iterator has yielded actually exists.

The value of this is somewhat dubious, and I cannot think of any usecase
where this functionality should be required. Furthermore, this option is
never set in our codebase, which means that it is essentially untested.
And last but not least, the `struct reftable_table` that is used to
implement it is about to go away.

So while we could refactor the code to not use a `reftable_table`, it
very much feels like a wasted effort. Let's just drop this code.

Signed-off-by: Patrick Steinhardt <ps@pks.im>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
reftable/iter.c
reftable/iter.h
reftable/reader.c