Re: Why is citext/regress failing on hamerkop?

Thomas Munro <thomas.munro@gmail.com>

From: Thomas Munro <thomas.munro@gmail.com>
To: "David E. Wheeler" <david@justatheory.com>
Cc: Oleg Tselebrovskiy <o.tselebrovskiy@postgrespro.ru>, pgsql-hackers <pgsql-hackers@postgresql.org>
Date: 2024-08-02T22:02:48Z
Lists: pgsql-hackers
On Sat, Aug 3, 2024 at 2:11 AM David E. Wheeler <david@justatheory.com> wrote:
> Haven’t been following this thread, but this post reminded me of an issue I saw with locales on Windows[1]. Could it be that the introduction of Universal CRT[2] in Windows 10 has improved UTF-8 support?

Yeah.  We have a few places that claim that Windows APIs can't do
UTF-8 and they have to do extra wchar_t conversions, but that doesn't
seem to be true on modern Windows.  Example:

https://github.com/postgres/postgres/blob/7926a9a80f6daf0fcc1feb1bee5c51fd001bc173/src/backend/utils/adt/pg_locale.c#L1814

I suspect that at least when the locale name is "en-US.UTF-8", then
the regular POSIXoid strcoll_l() function should just work™ and we
could delete all that stuff and save Windows users a lot of wasted CPU
cycles.



Commits

Same data as JSON: GET /api/v1/messages/:b64id/commits the thread's linked commits as JSON, with link sources. API reference →
  1. Small refactoring around ExecCreateTableAs().

  2. Skip citext_utf8 test on Windows.

  3. Fix lost Windows socket EOF events.

  4. Enable routine running of citext's UTF8-specific test cases.

  5. Drops in the CreateProcess calls for Win32 (essentially wrapping up the