pgsql: Remove endof macro

Lists: pgsql-committers
From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Remove endof macro
Date: 2017-09-05 19:08:06
Message-ID: E1dpJCg-00018P-7N@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-committers

Remove endof macro

It has not been used in a long time, and it doesn't seem safe anyway, so
drop it.

Reviewed-by: Michael Paquier <michael(dot)paquier(at)gmail(dot)com>
Reviewed-by: Ryan Murphy <ryanfmurphy(at)gmail(dot)com>

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/153a49bb331005bf70b1e76e69fe28f1c417cc91

Modified Files
--------------
src/include/c.h | 10 ++--------
1 file changed, 2 insertions(+), 8 deletions(-)


From: Andres Freund <andres(at)anarazel(dot)de>
To: Peter Eisentraut <peter_e(at)gmx(dot)net>
Cc: pgsql-committers(at)postgresql(dot)org
Subject: Re: pgsql: Remove endof macro
Date: 2017-09-05 19:10:13
Message-ID: 20170905191013.klfktiol3wd3yrrj@alap3.anarazel.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-committers

Hi,

On 2017-09-05 19:08:06 +0000, Peter Eisentraut wrote:
> Remove endof macro
>
> It has not been used in a long time, and it doesn't seem safe anyway, so
> drop it.

I've no problem removing this, but why isn't it safe? It's explicitly
allowed to compute (not dereference) the address of
end-of-array-plus-one.

Andres


From: Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>
To: Andres Freund <andres(at)anarazel(dot)de>
Cc: pgsql-committers(at)postgresql(dot)org
Subject: Re: pgsql: Remove endof macro
Date: 2017-09-07 02:37:02
Message-ID: 69deffdb-980f-9a25-73f4-ab8b5f976cd5@2ndquadrant.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-committers

On 9/5/17 15:10, Andres Freund wrote:
> On 2017-09-05 19:08:06 +0000, Peter Eisentraut wrote:
>> Remove endof macro
>>
>> It has not been used in a long time, and it doesn't seem safe anyway, so
>> drop it.
>
> I've no problem removing this, but why isn't it safe? It's explicitly
> allowed to compute (not dereference) the address of
> end-of-array-plus-one.

You are right. I misinterpreted some of the old commits.

--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services