Re: Rename 'lpp' to 'lp' in heapam.c

From: David Rowley <dgrowleyml(at)gmail(dot)com>
To: Yaphters W <yaphters(at)gmail(dot)com>
Cc: pgsql-hackers(at)lists(dot)postgresql(dot)org
Subject: Re: Rename 'lpp' to 'lp' in heapam.c
Date: 2023-05-03 02:18:17
Message-ID: CAApHDvr9gcDv+qN14ByRz1pVw949aeO3Fs-xJC8fzG_uK3QnLw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, 3 May 2023 at 12:16, Yaphters W <yaphters(at)gmail(dot)com> wrote:
> I just found the naming of the ItemId variables is not consistent in heapam.c. There are 13 'lpp's and 112 'lp's. Technically 'lpp' is correct as ItemId is a line pointer's pointer and there used to be code like "++lpp" for line pointer array iteration. Now that all the "++lpp" code has been removed and there are 100+ more occurrences of 'Ip' than 'lpp', I suggest we change 'lpp' to 'lp' to make things consistent and avoid confusion.

I don't really agree that one is any more correct than the other. I
also don't think we should be making changes like this as doing this
may give some false impression that we have some standard to follow
here that a local variable of a given type must be given a certain
name. To comply with such a standard seems like it would take close to
an endless number of patches which would just result in wasted
reviewer and committer time and give us nothing but pain while back
patching.

-1 from me.

David

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Geoghegan 2023-05-03 03:04:01 Re: [PATCH] Clarify the behavior of the system when approaching XID wraparound
Previous Message John Naylor 2023-05-03 01:46:15 Re: [PATCH] Clarify the behavior of the system when approaching XID wraparound