Introduce XLogRecPtrIsValid()
authorÁlvaro Herrera <[email protected]>
Thu, 6 Nov 2025 18:08:29 +0000 (19:08 +0100)
committerÁlvaro Herrera <[email protected]>
Thu, 6 Nov 2025 18:08:29 +0000 (19:08 +0100)
commitd2965f627fe35bfc9c212528159d95f46b8e83ef
treea946126277fe04a43a2f590d925f41a67bf52250
parentccfe28eb42370c1ce7b62c03fc4f2081ab6ba25d
Introduce XLogRecPtrIsValid()

XLogRecPtrIsInvalid() is inconsistent with the affirmative form of
macros used for other datatypes, and leads to awkward double negatives
in a few places.  This commit introduces XLogRecPtrIsValid(), which
allows code to be written more naturally.

This patch only adds the new macro.  XLogRecPtrIsInvalid() is left in
place, and all existing callers remain untouched.  This means all
supported branches can accept hypothetical bug fixes that use the new
macro, and at the same time any code that compiled with the original
formulation will continue to silently compile just fine.

Author: Bertrand Drouvot <[email protected]>
Backpatch-through: 13
Discussion: https://postgr.es/m/[email protected]
src/include/access/xlogdefs.h