From: Andres Freund <andres@anarazel.de>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-committers@lists.postgresql.org
Subject: Re: pgsql: "A void function may not return a value".
Date: Fri, 17 May 2019 21:44:35 -0700
Message-ID: <20190518044435.dpwg3aar43emt57w@alap3.anarazel.de> (raw)
In-Reply-To: <E1hRr9P-0001H9-Eu@gemulon.postgresql.org>
References: <E1hRr9P-0001H9-Eu@gemulon.postgresql.org>
Hi,
On 2019-05-18 04:40:51 +0000, Tom Lane wrote:
> "A void function may not return a value".
Darn. Thanks.
For C only, warn about a "return" statement with an expression in a function whose return type is "void", unless the expression type is also
"void". As a GNU extension, the latter case is accepted without a warning unless -Wpedantic is used.
And no, no thanks to you gcc. -pedantic is entirely unusable. It warns
about extensions we explicitly test for :(
- Andres
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: "A void function may not return a value".
In-Reply-To: <20190518044435.dpwg3aar43emt57w@alap3.anarazel.de>
References: <E1hRr9P-0001H9-Eu@gemulon.postgresql.org> <20190518044435.dpwg3aar43emt57w@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