s/pg_attribute_always_inline/pg_always_inline/?
Hi,
When reviewing the index prefetching patch I got a bit dismayed at how long
pg_attribute_always_inline is due to the way it triggers pgindent to format
stuff.
I propose that we remove the _attribute_ part of the name.
Given that it is implemented for compilers that don't use the
__attribute__((always_inline)) spelling, so the shorter name seems better
anyway.
Thoughts?
Greetings,
Andres Freund
Attachments:
v1-0001-Shorten-pg_attribute_always_inline-to-pg_always_i.patchtext/x-diff; charset=us-asciiDownload+74-75
On Wed, Apr 8, 2026 at 5:09 PM Andres Freund <andres@anarazel.de> wrote:
When reviewing the index prefetching patch I got a bit dismayed at how long
pg_attribute_always_inline is due to the way it triggers pgindent to format
stuff.
I had to significantly reorder function prototypes to avoid overly
long prototypes that had pg_attribute_always_inline. While perhaps not
strictly necessary, we shouldn't have to work around the fact that
pg_attribute_always_inline is an absurdly verbose symbol name.
I propose that we remove the _attribute_ part of the name.
+1
--
Peter Geoghegan
On 08.04.26 23:09, Andres Freund wrote:
Hi,
When reviewing the index prefetching patch I got a bit dismayed at how long
pg_attribute_always_inline is due to the way it triggers pgindent to format
stuff.I propose that we remove the _attribute_ part of the name.
Given that it is implemented for compilers that don't use the
__attribute__((always_inline)) spelling, so the shorter name seems better
anyway.
Yes, and the existing name is also kind of wrong even on GCC because the
macro does not expand to only an attribute but also includes the "inline".