pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Kyotaro Horiguchi <horikyota.ntt@gmail.com>
Cc: pgsql-hackers@lists.postgresql.org
Subject: Re: create_help.pl treats <literal> as replaceable
Date: Tue, 17 May 2022 11:09:23 -0400
Message-ID: <1581685.1652800163@sss.pgh.pa.us> (raw)
In-Reply-To: <20220517.174342.1884842412165214815.horikyota.ntt@gmail.com>
References: <20220517.174342.1884842412165214815.horikyota.ntt@gmail.com>

Kyotaro Horiguchi <horikyota.ntt@gmail.com> writes:
> I found it annoying that sql_help.c contains a literal parameter as a
> translatable string.

> The cause is that create_help.pl treats <literal>match</> as a
> replaceable. The attached excludes literals from translatable strings.

> By a quick look it seems to me that the "match" in "COPY.. HEADER
> match" is the first and only instance of a literal parameter as of
> PG15.

Isn't that a documentation bug rather than a problem with create_help?
I see what you're talking about:

    HEADER [ <replaceable class="parameter">boolean</replaceable> | <literal>match</literal> ]

but that just seems flat-out wrong.  If "match" is a keyword it should
be rendered like other keywords.  I'm not very interested in splitting
hairs about whether the grammar thinks it is a keyword --- it looks like
one to a user.  So I think

    HEADER [ <replaceable class="parameter">boolean</replaceable> | MATCH ]

would be a better solution.

			regards, tom lane





view thread (9+ messages)  latest in thread

Message-ID: <1581685.1652800163@sss.pgh.pa.us>
Permalink:  ../1581685.1652800163@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/1581685.1652800163@sss.pgh.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-hackers@postgresql.org
  Cc: tgl@sss.pgh.pa.us, horikyota.ntt@gmail.com, pgsql-hackers@lists.postgresql.org
  Subject: Re: create_help.pl treats <literal> as replaceable
  In-Reply-To: <1581685.1652800163@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox