pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Peter Eisentraut <peter@eisentraut.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Enable -Wstrict-prototypes and -Wold-style-definition by default
Date: Wed, 18 Mar 2026 13:31:58 +0000
Message-ID: <E1w2r09-000KvX-0b@gemulon.postgresql.org> (raw)

Enable -Wstrict-prototypes and -Wold-style-definition by default

Those are available in all gcc and clang versions that support C11 and as C11
is required as of f5e0186f865c, then we can add them without capability test.

Having them enabled by default avoid having to chase these manually like
11171fe1fc8, cdf4b9aff2, 0e72b9d440, 7069dbcc31, f1283ed6cc, 7b66e2c086,
e95126cf04 and 9f7c527af3 have done.

Also, readline headers trigger a lot of warnings with -Wstrict-prototypes, so
we make use of the system_header pragma to hide the warnings.

Author: Bertrand Drouvot <bertranddrouvot.pg@gmail.com>
Discussion: https://postgr.es/m/13d51b20-a69c-4ac1-8546-ec4fc278064f%40eisentraut.org
Discussion: https://postgr.es/m/aTFctZwWSpl2/LG5%40ip-10-97-1-34.eu-west-3.compute.internal

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/29bf4ee7496ca594495deb2599e8a44c6338525e

Modified Files
--------------
configure            | 8 ++++++++
configure.ac         | 8 ++++++++
meson.build          | 2 ++
src/bin/psql/input.h | 9 +++++++++
4 files changed, 27 insertions(+)



Message-ID: <E1w2r09-000KvX-0b@gemulon.postgresql.org>
Permalink:  ../E1w2r09-000KvX-0b@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1w2r09-000KvX-0b@gemulon.postgresql.org

 · 

reply

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 using the --to and --cc options:
  reply via email

  To: pgsql-committers@postgresql.org
  Cc: peter@eisentraut.org, pgsql-committers@lists.postgresql.org
  Subject: Re: pgsql: Enable -Wstrict-prototypes and -Wold-style-definition by default
  In-Reply-To: <E1w2r09-000KvX-0b@gemulon.postgresql.org>

* 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