Re: pgstat include expansion - Mailing list pgsql-hackers

From Amit Kapila
Subject Re: pgstat include expansion
Date
Msg-id CAA4eK1JPzbPM1-VM6U68K+SG6hyU+Srz2=UOPYQdT0=Z=oe6yg@mail.gmail.com
Whole thread
In response to Re: pgstat include expansion  (Nisha Moond <nisha.moond412@gmail.com>)
Responses Re: pgstat include expansion
List pgsql-hackers
On Mon, Feb 16, 2026 at 1:18 PM Nisha Moond <nisha.moond412@gmail.com> wrote:
>
> On Sat, Feb 14, 2026 at 3:45 AM Andres Freund <andres@anarazel.de> wrote:
> >
> >
> > conflict.h includes utils/timestamp.h, even though it only needs the
> > types. Using datatype/timestamp.h suffices (although it requires some fixups
> > elsewhere).
> >
>
> It works even without including "utils/timestamp.h" in conflict.h, as
> removing this header still allows the build and full tests to pass.
> This is likely because the required definitions are included
> indirectly, as all files using conflict.h already include either
> "access/commit_ts.h" (which includes "datatype/timestamp.h") or
> "datatype/timestamp.h" itself.
>
> To avoid possible issues in the future, if conflict.h is used in a
> file that does not include timestamp.h, it would be safer to include
> "datatype/timestamp.h" directly, which is sufficient and requires no
> fixups elsewhere.
>

Yeah, that sounds better.

> The attached patch includes the required change, and make check-world
> passes cleanly for it.
>

Good. I have not tested it myself but if others don't see a problem
with this, I can do the tests and push it.

--
With Regards,
Amit Kapila.



pgsql-hackers by date:

Previous
From: tushar
Date:
Subject: Re: Discrepancy in --no-tablespaces behavior between Tar and Plain-text formats
Next
From: Amit Kapila
Date:
Subject: Re: Add into REFRESH PUBLICATION parameter exception_behaviour