mirror of
https://github.com/postgres/postgres.git
synced 2025-06-13 07:41:39 +03:00
Move checking an explicit VARIADIC "any" argument into the parser.
This is more efficient and simpler . It does mean that an untyped NULL can no longer be used in such cases, which should be mentioned in Release Notes, but doesn't seem a terrible loss. The workaround is to cast the NULL to some array type. Pavel Stehule, reviewed by Jeevan Chalke.
This commit is contained in:
@ -8584,6 +8584,7 @@ generate_function_name(Oid funcid, int nargs, List *argnames, Oid *argtypes,
|
||||
Oid p_rettype;
|
||||
bool p_retset;
|
||||
int p_nvargs;
|
||||
Oid p_vatype;
|
||||
Oid *p_true_typeids;
|
||||
|
||||
proctup = SearchSysCache1(PROCOID, ObjectIdGetDatum(funcid));
|
||||
@ -8634,7 +8635,8 @@ generate_function_name(Oid funcid, int nargs, List *argnames, Oid *argtypes,
|
||||
NIL, argnames, nargs, argtypes,
|
||||
!use_variadic, true,
|
||||
&p_funcid, &p_rettype,
|
||||
&p_retset, &p_nvargs, &p_true_typeids, NULL);
|
||||
&p_retset, &p_nvargs, &p_vatype,
|
||||
&p_true_typeids, NULL);
|
||||
if ((p_result == FUNCDETAIL_NORMAL ||
|
||||
p_result == FUNCDETAIL_AGGREGATE ||
|
||||
p_result == FUNCDETAIL_WINDOWFUNC) &&
|
||||
|
Reference in New Issue
Block a user