Re: get rid of Pointer type, mostly

Robert Haas <robertmhaas@gmail.com>

From: Robert Haas <robertmhaas@gmail.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Peter Eisentraut <peter@eisentraut.org>, pgsql-hackers <pgsql-hackers@postgresql.org>
Date: 2025-11-24T19:32:24Z
Lists: pgsql-hackers

Commits

Same data as JSON: GET /api/v1/messages/:b64id/commits the thread's linked commits as JSON, with link sources. API reference →
  1. Remove no longer needed casts from Pointer

  2. Remove no longer needed casts to Pointer

  3. Change Pointer to void *

  4. Don't rely on pointer arithmetic with Pointer type

  5. Use more appropriate DatumGet* function

  6. Remove useless casts to Pointer

On Mon, Nov 24, 2025 at 1:26 PM Tom Lane <tgl@sss.pgh.pa.us> wrote:
> I don't understand leaving it in place for GIN.

I haven't tried removing it for GIN so I don't know how awkward that
would be or for what reasons, but...

> It's
> not like GIN indexes are some hoary backwater that nobody pays
> attention to.

...I almost feel like you're trolling with this comment. It is true
that we maintain that code, and I see in the commit log that there are
even some GIN-specific improvements in the recent past. But the
average PostgreSQL hacker can probably go years and years without ever
having to touch the GIN code. Hoary backwater might be overselling it,
but it's far enough in that direction that confining the need to be
aware of one specific PostgreSQL-ism just to GIN is not without value.

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