Re: Convert *GetDatum() and DatumGet*() macros to inline functions

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Aleksander Alekseev <aleksander(at)timescale(dot)com>
Cc: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Peter Eisentraut <peter(dot)eisentraut(at)enterprisedb(dot)com>
Subject: Re: Convert *GetDatum() and DatumGet*() macros to inline functions
Date: 2022-08-30 14:27:48
Message-ID: CA+Tgmob772QiakPJb-xFKTNbZULyAGxJHUcGLm7bcig=jSHiqw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, Aug 30, 2022 at 10:25 AM Aleksander Alekseev
<aleksander(at)timescale(dot)com> wrote:
> > Yeah, I don't see a reason to back-patch a change like this
>
> Maybe we should consider backporting at least 0001 patch, partially
> perhaps? I believe if fixes pretty cursed pieces of code, e.g:
>
> ```
> pg_cryptohash_ctx *context =
> - (pg_cryptohash_ctx *) PointerGetDatum(foundres);
> + (pg_cryptohash_ctx *) DatumGetPointer(foundres);
> ```

Sure, back-porting the bug fixes would make sense to me.

--
Robert Haas
EDB: http://www.enterprisedb.com

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Pavel Stehule 2022-08-30 14:28:05 Re: \pset xheader_width page as default? (Re: very long record lines in expanded psql output)
Previous Message Aleksander Alekseev 2022-08-30 14:25:32 Re: Convert *GetDatum() and DatumGet*() macros to inline functions