Re: [PATCH] Add hints for invalid binary encoding names in encode/decode functions - Mailing list pgsql-hackers

From Fujii Masao
Subject Re: [PATCH] Add hints for invalid binary encoding names in encode/decode functions
Date
Msg-id CAHGQGwFMy5T15RfujkL8UdG8us_qtO8pJgOjsK6cO2kF0tizTQ@mail.gmail.com
Whole thread Raw
In response to Re: [PATCH] Add hints for invalid binary encoding names in encode/decode functions  (Sugamoto Shinya <shinya34892@gmail.com>)
Responses Re: [PATCH] Add hints for invalid binary encoding names in encode/decode functions
List pgsql-hackers
On Wed, Nov 19, 2025 at 8:08 PM Sugamoto Shinya <shinya34892@gmail.com> wrote:
>
> Thanks everyone for reviewing my proposal. Please let me know if you have something to discuss here.

+                                errhint("Valid encodings are \"%s\",
\"%s\", \"%s\", and \"%s\".",
+                                                "base64",
"base64url", "escape", "hex")));

You changed the HINT message to use format arguments,
but I still think it's better to embed the values directly (e.g.,
Valid encodings are "base64", "base64url", "escape", and "hex".)
for consistency with similar HINT messages. If this message is
used in many places a parameterized style would help translators,
but that benefit doesn't apply here.

Attached is an updated version of the patch. I switched
the HINT message to the embedded form and updated the commit message.
Barring any objections, I'm thinking to commit this.

Regards,

--
Fujii Masao

Attachment

pgsql-hackers by date:

Previous
From: David Geier
Date:
Subject: Re: Performance issues with parallelism and LIMIT
Next
From: Daniel Gustafsson
Date:
Subject: Re: [PATCH] Add hints for invalid binary encoding names in encode/decode functions