Re: Add explicit casts in four places to simplehash.h

From: David Geier <geidav(dot)pg(at)gmail(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: PostgreSQL Developers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: Add explicit casts in four places to simplehash.h
Date: 2022-11-04 08:23:54
Message-ID: 0f0d2561-1190-1f45-0c5f-ed42f2c80aaf@gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 11/3/22 15:50, Tom Lane wrote:
> Seems reasonable, so done (I fixed one additional spot you missed).
Thanks!
> The bigger picture here is that we do actually endeavor to keep
> (most of) our headers C++ clean, but our tool cpluspluscheck misses
> these problems because it doesn't try to use these macros.
> I wonder whether there is a way to do better.

What about having a custom header alongside cpluspluscheck which
references all macros we care about?
We could start with the really big macros like the ones from
simplehash.h and add as we go.
I could give this a try if deemed useful.

--
David Geier
(ServiceNow)

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Drouvot, Bertrand 2022-11-04 08:25:52 Re: Report checkpoint progress with pg_stat_progress_checkpoint (was: Report checkpoint progress in server logs)
Previous Message sirisha chamarthi 2022-11-04 08:10:39 Reviving lost replication slots