Re: Add bms_offset_members() function for bitshifting Bitmapsets

From: David Rowley <dgrowleyml(at)gmail(dot)com>
To: Peter Eisentraut <peter(at)eisentraut(dot)org>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Chao Li <li(dot)evan(dot)chao(at)gmail(dot)com>, PostgreSQL Developers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: Add bms_offset_members() function for bitshifting Bitmapsets
Date: 2026-04-18 07:53:40
Message-ID: CAApHDvqJ_ZpO366cGMS2uheTzy0Kh8Qgk2hx+unfyKy1ifR6xw@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, 16 Apr 2026 at 07:17, Peter Eisentraut <peter(at)eisentraut(dot)org> wrote:
> Depending on what you end up doing, maybe a sprinkling of pg_nodiscard
> could be appropriate.

Yeah maybe. It wouldn't do any harm, at least.

I didn't do that in the patch I just sent as it felt like something we
should do or not do for all the bitmapset functions it's relevant for.
REALLOCATE_BITMAPSETS is meant to give us a stronger guarantee of
people forgetting to do this, as it would cause a breakage if there
were multiple pointers to the same set and only one of them got
updated.

David

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message SATYANARAYANA NARLAPURAM 2026-04-18 07:56:19 Bug: pg_get_viewdef() fails on GRAPH_TABLE views with lateral column references
Previous Message David Rowley 2026-04-18 07:49:57 Re: Add bms_offset_members() function for bitshifting Bitmapsets