Re: Re: [COMMITTERS] pgsql: Redefine _() to dgettext() instead of gettext() so that it uses

Поиск
Список
Период
Сортировка
От Alvaro Herrera
Тема Re: Re: [COMMITTERS] pgsql: Redefine _() to dgettext() instead of gettext() so that it uses
Дата
Msg-id 20090307235339.GD3821@alvh.no-ip.org
обсуждение исходный текст
Ответ на Re: Re: [COMMITTERS] pgsql: Redefine _() to dgettext() instead of gettext() so that it uses  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
Tom Lane wrote:
> Alvaro Herrera <alvherre@commandprompt.com> writes:
> > Understood.  In fact, after having a look at this patch and giving it a
> > little refactoring I think it's pretty obvious; right now we're calling
> > bind_textdomain_codeset only for the main domain, and with this patch we
> > also set it for all other domains we use.

> More generally, should we push the bindtextdomain calls themselves into
> the new function (and perhaps call it something else than
> SetDomainCodeSet)?  Seems like logically this should be thought of as
> all one operation, ie, it's not clear to me that it ever makes sense to
> call bindtextdomain without also worrying about encoding.

I'm not sure that can be made to work easily.  On the backend itself we
call bindtextdomain in set_pglocale_pgservice() which is also used by
programs in src/bin/.  Shuffling things in there would be more involved
than seems worth.

As for names, how about pg_bind_textdomain_codeset?

--
Alvaro Herrera                                http://www.CommandPrompt.com/
The PostgreSQL Company - Command Prompt, Inc.

Вложения

В списке pgsql-hackers по дате отправления:

Предыдущее
От: Andrew Dunstan
Дата:
Сообщение: Re: small parallel restore optimization
Следующее
От: "Dickson S. Guedes"
Дата:
Сообщение: ERROR: "failed to locate grouping columns"