Re: NAMEDATALEN increase because of non-latin languages - Mailing list pgsql-hackers

From Robert Haas
Subject Re: NAMEDATALEN increase because of non-latin languages
Date
Msg-id CA+TgmoY2WSF0uHRhYi4y1vx-o735-yAn1VrKwrd6VgfnaELHog@mail.gmail.com
Whole thread Raw
In response to Re: NAMEDATALEN increase because of non-latin languages  (Andres Freund <andres@anarazel.de>)
Responses Re: NAMEDATALEN increase because of non-latin languages  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
On Thu, Jun 23, 2022 at 5:49 PM Andres Freund <andres@anarazel.de> wrote:
> I was thinking we'd basically do it wherever we do a GETSTRUCT() today.
>
> A first step could be to transform code like
>     (Form_pg_attribute) GETSTRUCT(tuple)
> into
>    GETSTRUCT(pg_attribute, tuple)
>
> then, in a subsequent step, we'd redefine GETSTRUCT as something
> #define GESTRUCT(catalog, tuple) tuple_to_struct_##catalog(tuple)

That seems a little fraught, because you'd be turning what's now
basically a trivial operation into a non-trivial operation involving
memory allocation.

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



pgsql-hackers by date:

Previous
From: Andres Freund
Date:
Subject: Re: NAMEDATALEN increase because of non-latin languages
Next
From: Tom Lane
Date:
Subject: Re: NAMEDATALEN increase because of non-latin languages