Add a missing comment for PGPROC.pgprocno

From: Aleksander Alekseev <aleksander(at)timescale(dot)com>
To: PostgreSQL Development <pgsql-hackers(at)postgresql(dot)org>
Subject: Add a missing comment for PGPROC.pgprocno
Date: 2022-09-08 17:16:07
Message-ID: CAJ7c6TOs9Dh3KNR2kiQJ3Ow0=TBucL_57DAbm--2p8w5x_8YXQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi hackers,

I tried to understand some implementation details of ProcArray and
discovered that this is a bit challenging to do due to a missing
comment for PGPROC.pgprocno. E.g. it's hard to understand why
ProcArrayAdd() preserves procArray->pgprocnos[] sorted by (PGPROC *)
if actually the sorting is done by pgprocno. Took me some time to
figure this out.

Here is the patch that fixes this. Hopefully this will save some time
for the newcomers.

--
Best regards,
Aleksander Alekseev

Attachment Content-Type Size
v1-0001-Add-a-missing-comment-for-PGPROC.pgprocno.patch application/octet-stream 1.0 KB

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Andres Freund 2022-09-08 17:20:29 Re: [BUG] wrong FK constraint name when colliding name on ATTACH
Previous Message Andres Freund 2022-09-08 17:07:40 Re: Minimum bison and flex versions