agora inbox for pgsql-committers@postgresql.org
help / color / mirror / Atom feedFrom: Peter Eisentraut <peter@eisentraut.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Fix MSVC warnings from new timezone code
Date: Wed, 05 Aug 2026 18:10:24 +0000
Message-ID: <E1wrg4O-00000000KWm-2MCR@gemulon.postgresql.org> (raw)
Fix MSVC warnings from new timezone code
The new timezone code from commit aeb07c55fab introduced a few new
compiler warnings from MSVC:
../src/timezone/zic.c(353): warning C5287: operands are different enum types '<unnamed-enum-RF_NAME>' and '<unnamed-enum-LF_TARGET>'; use an explicit cast to silence this warning
../src/timezone/zic.c(353): warning C5287: operands are different enum types '<unnamed-enum-RF_NAME>' and '<unnamed-enum-LP_YEAR>'; use an explicit cast to silence this warning
../src/timezone/zic.c(1654): warning C4146: unary minus operator applied to unsigned type, result still unsigned
Silence these warnings with pragmas.
In order not to make future code merges more complicated, the pragmas
apply to the entire file, not only to the specific code sections where
they are needed. This also prevents further warnings of the same
kinds creeping in.
Reviewed-by: Tom Lane <tgl@sss.pgh.pa.us>
Discussion: https://www.postgresql.org/message-id/flat/2294297.1780270682%40sss.pgh.pa.us
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/0d8e41fe1c80d1310e0eed0f66af82f60e506c69
Modified Files
--------------
src/timezone/zic.c | 11 +++++++++++
1 file changed, 11 insertions(+)
Message-ID: <E1wrg4O-00000000KWm-2MCR@gemulon.postgresql.org>
Permalink: ../E1wrg4O-00000000KWm-2MCR@gemulon.postgresql.org/
Also on: postgresql.org/message-id/E1wrg4O-00000000KWm-2MCR@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: Fix MSVC warnings from new timezone code
In-Reply-To: <E1wrg4O-00000000KWm-2MCR@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 agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox