On 17.09.25 18:26, Jacob Champion wrote:
On Tue, Sep 16, 2025 at 10:21 PM Peter Eisentraut wrote:
I think there is agreement that the PointerIsValid() macro is pretty
useless. This patch proposes to remove it. There have been a few
recent mini-discussions in other threads that appear to supp
On Wed, Sep 17, 2025 at 11:21:10AM -0500, Nathan Bossart wrote:
> On Wed, Sep 17, 2025 at 10:15:10AM -0400, Peter Geoghegan wrote:
>>> There were the usual concerns about code churn and backpatching and so
>>> on, but I think in the end the change is not that big and it's in pretty
>>> boring posit
On Thu, 18 Sept 2025 at 03:55, Robert Haas wrote:
> I agree that we should prefer foo != NULL, but if the surrounding code
> in a particular location just tests if (foo), then it may be better in
> that case to go that route.
+1. I generally do (var != NULL) for pointers rather than (var). I
thin
On Tue, Sep 16, 2025 at 10:21 PM Peter Eisentraut wrote:
>
> I think there is agreement that the PointerIsValid() macro is pretty
> useless. This patch proposes to remove it. There have been a few
> recent mini-discussions in other threads that appear to support this. [0][1]
Patch LGTM, and I l
On Wed, Sep 17, 2025 at 10:15:10AM -0400, Peter Geoghegan wrote:
> On Wed, Sep 17, 2025 at 1:21 AM Peter Eisentraut wrote:
>> I think there is agreement that the PointerIsValid() macro is pretty
>> useless. This patch proposes to remove it. There have been a few
>> recent mini-discussions in oth
On Wed, Sep 17, 2025 at 4:12 AM Chao Li wrote:
> Given the context of replacing PointerIsValid(x), I think if (foo != NULL) is
> slightly better than if (x), because that explicitly shows the intent of
> checking pointers, while if (x) works for both pointers and integers.
I agree that we shoul
On Wed, Sep 17, 2025 at 1:21 AM Peter Eisentraut wrote:
> I think there is agreement that the PointerIsValid() macro is pretty
> useless. This patch proposes to remove it. There have been a few
> recent mini-discussions in other threads that appear to support this. [0][1]
I'm also in favor of r
> On Sep 17, 2025, at 13:21, Peter Eisentraut wrote:
>
> I think there is agreement that the PointerIsValid() macro is pretty useless.
> This patch proposes to remove it. There have been a few recent
> mini-discussions in other threads that appear to support this. [0][1]
>
> There were the
[email protected]
[1]:
https://www.postgresql.org/message-id/[email protected] af26264d850a40e5c9c4e73fea81189ca9f6bb6a Mon Sep 17 00:00:00 2001
From: Peter Eisentraut
Date: Wed, 17 Sep 2025 07:11:05 +0200
Subject: [PATCH] R