C nitpick about pgwin32_dispatch_queued_signals()

From: Christian Ullrich <chris(at)chrullrich(dot)net>
To: "pgsql-hackers(at)lists(dot)postgresql(dot)org" <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: C nitpick about pgwin32_dispatch_queued_signals()
Date: 2025-11-02 13:05:47
Message-ID: cc4ef8db-f8dc-4347-8a22-e7ebf44c0308@chrullrich.net
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hello,

the current MSVC compiler deems it necessary to issue

warning C4053: one void operand for '?:'

for a line with CHECK_FOR_INTERRUPTS(). This boils down to this bit of
miscadmin.h (line 116 in master):

#define INTERRUPTS_PENDING_CONDITION() \
(unlikely(UNBLOCKED_SIGNAL_QUEUE()) ?
pgwin32_dispatch_queued_signals() : 0, \
unlikely(InterruptPending))
#endif

The C spec says that of the possible results of the :? operator, either
none or both can be void, and pgwin32_dispatch_queued_signals() is void
(and has been as far back as I can find it).

Does that matter?

--
Christian

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Ranier Vilela 2025-11-02 14:59:35 Avoid overflow (src/backend/utils/adt/formatting.c)
Previous Message Mihail Nikalayeu 2025-11-02 12:33:40 Re: test_json_parser/002_inline is kind of slow