Re: PRI?64 vs Visual Studio (2022)

From: Peter Eisentraut <peter(at)eisentraut(dot)org>
To: Kyotaro Horiguchi <horikyota(dot)ntt(at)gmail(dot)com>, pgsql-hackers(at)lists(dot)postgresql(dot)org
Subject: Re: PRI?64 vs Visual Studio (2022)
Date: 2025-04-01 13:04:37
Message-ID: 001bdc3b-ef94-4f24-b017-ac8ff0a2ea55@eisentraut.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 31.03.25 08:28, Kyotaro Horiguchi wrote:
> If you're already aware of this and have taken it into account, please
> feel free to ignore this.
>
> As described in the recent commit a0ed19e0a9e, many %ll? format
> specifiers are being replaced with %<PRI?64>.
>
> I hadn’t paid much attention to this before, but I happened to check
> how this behaves on Windows, and it seems that with VS2022, PRId64
> expands to "%lld". As a result, I suspect the gettext message catalog
> won't match these messages correctly.

I think this is working correctly. Gettext has a built-in mechanism to
translate the %<PRI...> back to the appropriate %lld or %ld. See also
<https://www.gnu.org/software/gettext/manual/html_node/c_002dformat.html>.

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Daniel Gustafsson 2025-04-01 13:11:51 Re: pgsql: Add support for OAUTHBEARER SASL mechanism
Previous Message Christoph Berg 2025-04-01 13:03:25 Re: pgsql: Add support for OAUTHBEARER SASL mechanism