From: Andres Freund <andres@anarazel.de>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-committers@postgresql.org
Subject: Re: pgsql: Add pg_noinline macro to c.h.
Date: Fri, 13 Oct 2017 15:43:46 -0700
Message-ID: <20171013224346.x2jlstni2dexnuis@alap3.anarazel.de> (raw)
In-Reply-To: <21403.1507933928@sss.pgh.pa.us>
References: <E1e37Vv-0004M0-HT@gemulon.postgresql.org>
<21403.1507933928@sss.pgh.pa.us>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-committers>
On 2017-10-13 18:32:08 -0400, Tom Lane wrote:
> Andres Freund <andres@anarazel.de> writes:
> > Add pg_noinline macro to c.h.
>
> I think you want this to be parenthesized so that pgindent doesn't
> go nuts when you use it. At least, that was the reason why
> pg_attribute_noreturn() has parens. Even if the current version
> of pgindent doesn't have that problem
The current pgindent actually generates *better* layout with pg_noinline
rather than pg_noinline(). The latter forces a linebreak both in
declarations and definitions like:
static pg_noinline()
HeapTuple SearchCatCacheMiss(CatCache *cache,
static pg_noinline()
HeapTuple
SearchCatCacheMiss(CatCache *cache,
One difference to pg_attribute_noreturn() is that for function
definitions - and noinline needs to be present there IME - you can't put
it after the parameter list.
> I would argue that consistency demands that you spell this pg_attribute_noinline().
Hm, I personally find inline vs pg_noinline more aesthetically pleasing.
Greetings,
Andres Freund
--
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-committers@postgresql.org
Cc: andres@anarazel.de, tgl@sss.pgh.pa.us
Subject: Re: pgsql: Add pg_noinline macro to c.h.
In-Reply-To: <20171013224346.x2jlstni2dexnuis@alap3.anarazel.de>
References: <E1e37Vv-0004M0-HT@gemulon.postgresql.org> <21403.1507933928@sss.pgh.pa.us> <20171013224346.x2jlstni2dexnuis@alap3.anarazel.de>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox