From 59a2111b23f6ceec4c777d68e20c1027d3c57c6f Mon Sep 17 00:00:00 2001 From: Alvaro Herrera Date: Mon, 28 Mar 2016 14:12:00 -0300 Subject: Improve internationalization of messages involving type names Change the slightly different variations of the message function FOO must return type BAR to a single wording, removing the variability in type name so that they all create a single translation entry; since the type name is not to be translated, there's no point in it being part of the message anyway. Also, change them all to use the same quoting convention, namely that the function name is not to be quoted but the type name is. (I'm not quite sure why this is so, but it's the clear majority.) Some similar messages such as "encoding conversion function FOO must ..." are also changed. --- src/backend/parser/parse_clause.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/backend/parser/parse_clause.c') diff --git a/src/backend/parser/parse_clause.c b/src/backend/parser/parse_clause.c index 4d9febee642..8dbe9437419 100644 --- a/src/backend/parser/parse_clause.c +++ b/src/backend/parser/parse_clause.c @@ -758,8 +758,8 @@ transformRangeTableSample(ParseState *pstate, RangeTableSample *rts) if (get_func_rettype(handlerOid) != TSM_HANDLEROID) ereport(ERROR, (errcode(ERRCODE_WRONG_OBJECT_TYPE), - errmsg("function %s must return type \"tsm_handler\"", - NameListToString(rts->method)), + errmsg("function %s must return type \"%s\"", + NameListToString(rts->method), "tsm_handler"), parser_errposition(pstate, rts->location))); /* OK, run the handler to get TsmRoutine, for argument type info */ -- cgit v1.2.3