Re: Get ride of pqbool artifact (src/interfaces/libpq/libpq-fe.h)

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Ranier Vilela <ranier(dot)vf(at)gmail(dot)com>
Cc: Pg Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Get ride of pqbool artifact (src/interfaces/libpq/libpq-fe.h)
Date: 2025-09-02 19:44:20
Message-ID: 674317.1756842260@sss.pgh.pa.us
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Ranier Vilela <ranier(dot)vf(at)gmail(dot)com> writes:
> In libpq-fe.h has an artifact pre C99, pqbool.
> IMO this is not more necessary, once Postgres supports C99
> and bool becomes standard.

> So get ride of pqbool and use bool instead.

We can't really remove that typedef ever, because application code
might be using it. Unlikely I concede, but nonetheless it's part
of libpq's exposed API.

We might be able to s/pqbool/bool/ in the struct, but I kind of
wonder if that wouldn't be an ABI break: at the very least it
would lead to subtle changes in code compiled to use the struct.
On the whole I see little value in taking any risk here.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Jacob Champion 2025-09-02 19:51:50 Re: Get ride of pqbool artifact (src/interfaces/libpq/libpq-fe.h)
Previous Message Ranier Vilela 2025-09-02 19:19:56 Get ride of pqbool artifact (src/interfaces/libpq/libpq-fe.h)