Re: IndexTupleDSize macro seems redundant - Mailing list pgsql-hackers

From Amit Kapila
Subject Re: IndexTupleDSize macro seems redundant
Date
Msg-id CAA4eK1+qNuT2iY+gL-yi-Sn-aj=2y7hBD3GFFRrxh6hV-U+X6w@mail.gmail.com
Whole thread Raw
In response to IndexTupleDSize macro seems redundant  (Ildar Musin <i.musin@postgrespro.ru>)
List pgsql-hackers
On Mon, Nov 20, 2017 at 9:01 PM, Ildar Musin <i.musin@postgrespro.ru> wrote:
> Hi all,
>
> While I was looking through the indexes code I got confused by couple of
> macros - IndexTupleSize() and IndexTupleDSize() - which seem to do the same
> thing with only difference that the first one takes pointer as an argument
> while the second one takes struct. And in most cases IndexTupleDSize() is
> used with dereferencing of index tuple where IndexTupleSize() would suit
> perfectly. Is there a particular reason to have them both? I've made a patch
> that removes IndexTupleDSize macro. All the tests have passed.
>

+1.  I was also once confused with these macros.  I think this is a
good cleanup.  On a quick look, I don't see any problem with your
changes.

-- 
With Regards,
Amit Kapila.
EnterpriseDB: http://www.enterprisedb.com


pgsql-hackers by date:

Previous
From: Robert Haas
Date:
Subject: Re: feature request: consume asynchronous notification via a function
Next
From: Andreas Karlsson
Date:
Subject: Re: [HACKERS] GnuTLS support