| From: | Álvaro Herrera <alvherre(at)kurilemu(dot)de> |
|---|---|
| To: | Peter Smith <smithpb2250(at)gmail(dot)com> |
| Cc: | PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
| Subject: | Re: Redundant/mis-use of _(x) gettext macro? |
| Date: | 2026-04-01 11:52:02 |
| Message-ID: | 202604011144.jeo56tazdx6z@alvherre.pgsql |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
On 2026-Apr-01, Peter Smith wrote:
> Hi.
>
> As originally reported [1] in the EXCEPT (TABLE ...) thread, I felt
> the _() gettext macro is mis-used when it contains nothing but a
> quoted format string.
No, you feel wrong -- this is necessary so that the translator has
control over the quoting style of a list of items. Not all translations
use double quoting. Some examples from different language files:
msgstr "unbekannte Komprimierungsoption: »%s«"
msgstr "opción de compresión no reconocida: «%s»"
msgstr "option de compression inconnue : « %s »"
msgstr "tidak dapat menentukan encoding untuk lokal « %s » : codesetnya adalah « %s »"
--
Álvaro Herrera PostgreSQL Developer — https://www.EnterpriseDB.com/
"In fact, the basic problem with Perl 5's subroutines is that they're not
crufty enough, so the cruft leaks out into user-defined code instead, by
the Conservation of Cruft Principle." (Larry Wall, Apocalypse 6)
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Junwang Zhao | 2026-04-01 11:56:10 | Re: Eliminating SPI / SQL from some RI triggers - take 3 |
| Previous Message | John Naylor | 2026-04-01 11:48:10 | Re: vectorized CRC on ARM64 |