1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-05 07:21:24 +03:00

Make a code-cleanup pass over the collations patch.

This patch is almost entirely cosmetic --- mostly cleaning up a lot of
neglected comments, and fixing code layout problems in places where the
patch made lines too long and then pgindent did weird things with that.
I did find a bug-of-omission in equalTupleDescs().
This commit is contained in:
Tom Lane
2011-04-22 17:43:18 -04:00
parent 0cfdc1c657
commit 9e9b9ac7d1
24 changed files with 179 additions and 118 deletions

View File

@ -286,10 +286,10 @@ analyzeCTE(ParseState *pstate, CommonTableExpr *cte)
else
{
/*
* Verify that the previously determined output column types match
* what the query really produced. We have to check this because the
* recursive term could have overridden the non-recursive term, and we
* don't have any easy way to fix that.
* Verify that the previously determined output column types and
* collations match what the query really produced. We have to check
* this because the recursive term could have overridden the
* non-recursive term, and we don't have any easy way to fix that.
*/
ListCell *lctlist,
*lctyp,
@ -366,11 +366,11 @@ analyzeCTETargetList(ParseState *pstate, CommonTableExpr *cte, List *tlist)
Assert(cte->ctecolnames == NIL);
/*
* We need to determine column names and types. The alias column names
* override anything coming from the query itself. (Note: the SQL spec
* says that the alias list must be empty or exactly as long as the output
* column set; but we allow it to be shorter for consistency with Alias
* handling.)
* We need to determine column names, types, and collations. The alias
* column names override anything coming from the query itself. (Note:
* the SQL spec says that the alias list must be empty or exactly as long
* as the output column set; but we allow it to be shorter for consistency
* with Alias handling.)
*/
cte->ctecolnames = copyObject(cte->aliascolnames);
cte->ctecoltypes = cte->ctecoltypmods = cte->ctecolcollations = NIL;