Re: Rename 'lpp' to 'lp' in heapam.c - Mailing list pgsql-hackers

From David Rowley
Subject Re: Rename 'lpp' to 'lp' in heapam.c
Date
Msg-id CAApHDvr9gcDv+qN14ByRz1pVw949aeO3Fs-xJC8fzG_uK3QnLw@mail.gmail.com
Whole thread Raw
In response to Rename 'lpp' to 'lp' in heapam.c  (Yaphters W <yaphters@gmail.com>)
Responses Re: Rename 'lpp' to 'lp' in heapam.c
List pgsql-hackers
On Wed, 3 May 2023 at 12:16, Yaphters W <yaphters@gmail.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
pointerarray 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



pgsql-hackers by date:

Previous
From: John Naylor
Date:
Subject: Re: [PATCH] Clarify the behavior of the system when approaching XID wraparound
Next
From: Peter Geoghegan
Date:
Subject: Re: [PATCH] Clarify the behavior of the system when approaching XID wraparound