mirror of
https://github.com/postgres/postgres.git
synced 2025-11-16 15:02:33 +03:00
Support "variadic" functions, which can accept a variable number of arguments
so long as all the trailing arguments are of the same (non-array) type. The function receives them as a single array argument (which is why they have to all be the same type). It might be useful to extend this facility to aggregates, but this patch doesn't do that. This patch imposes a noticeable slowdown on function lookup --- a follow-on patch will fix that by adding a redundant column to pg_proc. Pavel Stehule
This commit is contained in:
@@ -8,7 +8,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $PostgreSQL: pgsql/src/backend/nodes/outfuncs.c,v 1.326 2008/04/29 14:59:16 alvherre Exp $
|
||||
* $PostgreSQL: pgsql/src/backend/nodes/outfuncs.c,v 1.327 2008/07/16 01:30:22 tgl Exp $
|
||||
*
|
||||
* NOTES
|
||||
* Every node type that can appear in stored rules' parsetrees *must*
|
||||
@@ -1610,6 +1610,7 @@ _outFuncCall(StringInfo str, FuncCall *node)
|
||||
WRITE_NODE_FIELD(args);
|
||||
WRITE_BOOL_FIELD(agg_star);
|
||||
WRITE_BOOL_FIELD(agg_distinct);
|
||||
WRITE_BOOL_FIELD(func_variadic);
|
||||
WRITE_INT_FIELD(location);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user