1
0
mirror of https://github.com/postgres/postgres.git synced 2025-06-14 18:42:34 +03:00

Pass incompletely-transformed aggregate argument lists as separate parameters

to transformAggregateCall, instead of abusing fields in Aggref to carry them
temporarily.  No change in functionality but hopefully the code is a bit
clearer now.  Per gripe from Gokulakannan Somasundaram.
This commit is contained in:
Tom Lane
2010-03-17 16:52:38 +00:00
parent f248e11f70
commit 93324355eb
3 changed files with 15 additions and 15 deletions

View File

@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/backend/parser/parse_func.c,v 1.222 2010/02/26 02:00:52 momjian Exp $
* $PostgreSQL: pgsql/src/backend/parser/parse_func.c,v 1.223 2010/03/17 16:52:38 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@ -381,10 +381,7 @@ ParseFuncOrColumn(ParseState *pstate, List *funcname, List *fargs,
aggref->aggfnoid = funcid;
aggref->aggtype = rettype;
/* args and aggorder will be modified by transformAggregateCall */
aggref->args = fargs;
aggref->aggorder = agg_order;
/* aggdistinct will be set by transformAggregateCall */
/* args, aggorder, aggdistinct will be set by transformAggregateCall */
aggref->aggstar = agg_star;
/* agglevelsup will be set by transformAggregateCall */
aggref->location = location;
@ -419,7 +416,7 @@ ParseFuncOrColumn(ParseState *pstate, List *funcname, List *fargs,
parser_errposition(pstate, location)));
/* parse_agg.c does additional aggregate-specific processing */
transformAggregateCall(pstate, aggref, agg_distinct);
transformAggregateCall(pstate, aggref, fargs, agg_order, agg_distinct);
retval = (Node *) aggref;
}