pgsql: Fix incorrect comment for get_agg_clause_costs

From: David Rowley <drowley(at)postgresql(dot)org>
To: pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: pgsql: Fix incorrect comment for get_agg_clause_costs
Date: 2021-07-26 02:56:28
Message-ID: E1m7qn6-0007Am-Fd@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Fix incorrect comment for get_agg_clause_costs

Adjust the header comment in get_agg_clause_costs so that it matches what
the function currently does. No recursive searching has been done ever
since 0a2bc5d61. It also does not determine the aggtranstype like the
comment claimed. That's all done in preprocess_aggref().
preprocess_aggref also now determines the numOrderedAggs, so remove the
mention that get_agg_clause_costs also calculates "counts".

Normally, since this is just an adjustment of a comment it might not be
worth back-patching, but since this code is new to PG14 and that version
is still in beta, then it seems worth having the comments match.

Discussion: https://postgr.es/m/CAApHDvrrGrTJFPELrjx0CnDtz9B7Jy2XYW3Z2BKifAWLSaJYwQ@mail.gmail.com
Backpatch-though: 14

Branch
------
REL_14_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/dece64a941457686184654968ac1ded58b7d4ee8

Modified Files
--------------
src/backend/optimizer/prep/prepagg.c | 28 ++++++++++++----------------
1 file changed, 12 insertions(+), 16 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Tom Lane 2021-07-26 03:25:27 pgsql: Harden pg_stat_statements tests against CLOBBER_CACHE_ALWAYS.
Previous Message David Rowley 2021-07-26 02:55:58 pgsql: Fix incorrect comment for get_agg_clause_costs