heapam: Move logic to handle HEAP_MOVED into a helper function master github/master
authorAndres Freund <andres@anarazel.de>
Fri, 19 Dec 2025 18:28:34 +0000 (13:28 -0500)
committerAndres Freund <andres@anarazel.de>
Fri, 19 Dec 2025 18:28:34 +0000 (13:28 -0500)
commit548de59d93d5593d5ef5354241510d57b68959db
tree10a09e862a34df4a68234db90472e2638ad0b3ee
parent09ae2c8bac8db409a8cd0b8ee438ea7526deb4c3
heapam: Move logic to handle HEAP_MOVED into a helper function

Before we dealt with this in 6 near identical and one very similar copy.

The helper function errors out when encountering a
HEAP_MOVED_IN/HEAP_MOVED_OUT tuple with xvac considered current or
in-progress. It'd be preferrable to do that change separately, but otherwise
it'd not be possible to deduplicate the handling in
HeapTupleSatisfiesVacuum().

Reviewed-by: Heikki Linnakangas <hlinnaka@iki.fi>
Discussion: https://postgr.es/m/lxzj26ga6ippdeunz6kuncectr5gfuugmm2ry22qu6hcx6oid6@lzx3sjsqhmt6
Discussion: https://postgr.es/m/6rgb2nvhyvnszz4ul3wfzlf5rheb2kkwrglthnna7qhe24onwr@vw27225tkyar
src/backend/access/heap/heapam_visibility.c