Re: Make uselocale protection more consistent
От
Peter Eisentraut
Тема
Re: Make uselocale protection more consistent
Дата
Msg-id
fe6fafd1-8bf3-9307-b1d0-e5074722452a@eisentraut.org
Ответ на
Make uselocale protection more consistent (Tristan Partin)
Список
Дерево обсуждения
Make uselocale protection more consistent "Tristan Partin" <tristan@neon.tech>
Re: Make uselocale protection more consistent Peter Eisentraut <peter@eisentraut.org>
Re: Make uselocale protection more consistent Thomas Munro <thomas.munro@gmail.com>
Re: Make uselocale protection more consistent Peter Eisentraut <peter@eisentraut.org>
Re: Make uselocale protection more consistent "Tristan Partin" <tristan@neon.tech>
Re: Make uselocale protection more consistent Peter Eisentraut <peter@eisentraut.org>
Re: Make uselocale protection more consistent "Tristan Partin" <tristan@neon.tech>
On 27.06.23 17:02, Tristan Partin wrote: > This is a patch which implements an issue discussed in bug #17946[0]. It > doesn't fix the overarching issue of the bug, but merely a consistency > issue which was found while analyzing code by Heikki. I had originally > submitted the patch within that thread, but for visibility and the > purposes of the commitfest, I have re-sent it in its own thread. > > [0]: https://www.postgresql.org/message-id/49dfcad8-90fa-8577-008f-d142e61af46b@iki.fi I notice that HAVE_USELOCALE was introduced much later than HAVE_LOCALE_T, and at the time the code was already using uselocale(), so perhaps the introduction of HAVE_USELOCALE was unnecessary and should be reverted. I think it would be better to keep HAVE_LOCALE_T as encompassing any of the various locale_t-using functions, rather than using HAVE_USELOCALE as a proxy for them. Otherwise you create weird situations like having #ifdef HAVE_WCSTOMBS_L inside #ifdef HAVE_USELOCALE, which doesn't make sense, I think.
В списке pgsql-hackers по дате отправления