pgsql: Disable -Wsometimes-uninitialized warnings in the 9.2 branch.

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: pgsql: Disable -Wsometimes-uninitialized warnings in the 9.2 branch.
Date: 2021-12-13 06:28:23
Message-ID: E1mweox-0000zc-I7@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Disable -Wsometimes-uninitialized warnings in the 9.2 branch.

In 9.2, we didn't yet teach the compiler that elog(ERROR) doesn't
return, which means that the compiler's opinion about whether
variable dereferences are reachable isn't worth much. Back-patching
the commits that fixed that seems unduly invasive, so instead silence
related complaints with a big hammer.

-Wsometimes-uninitialized is a clang-ism; gcc seems to spell
this warning option differently. However, I do not observe
any such compiler warnings in 9.2 with gcc 11.2.1, so for now
we needn't do anything for gcc.

Discussion: https://postgr.es/m/d0316012-ece7-7b7e-2d36-9c38cb77cb3b@enterprisedb.com

Branch
------
REL9_2_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/cea316881f1f109fe06243f1294313ead913b498

Modified Files
--------------
configure | 67 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
configure.in | 8 ++++++++
2 files changed, 75 insertions(+)

Browse pgsql-committers by date

  From Date Subject
Next Message Michael Paquier 2021-12-13 08:08:42 Re: pgsql: Check that we have a working tar before trying to use it
Previous Message Tom Lane 2021-12-13 05:52:18 pgsql: Fix function return type confusion