Re: Something in our JIT code is screwing up PG_PRINTF_ATTRIBUTE - Mailing list pgsql-hackers

From Jelte Fennema-Nio
Subject Re: Something in our JIT code is screwing up PG_PRINTF_ATTRIBUTE
Date
Msg-id CAGECzQTZs4OeAwdAEa_uq=Qjoz_S3yOre9usNio8LBigEweiqw@mail.gmail.com
Whole thread Raw
In response to Re: Something in our JIT code is screwing up PG_PRINTF_ATTRIBUTE  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
On Sat, 6 Dec 2025 at 21:40, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> Yeah.  However, selecting different PG_PRINTF_ATTRIBUTE values for
> C and C++ mode seems to get the job done.  I've confirmed the attached
> silences these warnings for me when mixing-and-matching gcc and clang.

I've definitely run into this myself a bunch of times. I'm wondering
if we should do this for more of these compiler features, e.g.
HAVE_TYPEOF is strictly wrong for C++ builds afaict[1].

[1]: https://www.postgresql.org/message-id/flat/CAGECzQR21OnnKiZO_1rLWO0-16kg1JBxnVq-wymYW0-_1cUNtg@mail.gmail.com



pgsql-hackers by date:

Previous
From: jian he
Date:
Subject: Re: PATCH: jsonpath string methods: lower, upper, initcap, l/r/btrim, replace, split_part
Next
From: Marcos Pegoraro
Date:
Subject: Re: Initial COPY of Logical Replication is too slow