1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-30 11:03:19 +03:00

8.4 pgindent run, with new combined Linux/FreeBSD/MinGW typedef list

provided by Andrew.
This commit is contained in:
Bruce Momjian
2009-06-11 14:49:15 +00:00
parent 4e86efb4e5
commit d747140279
654 changed files with 11900 additions and 11387 deletions

View File

@ -15,7 +15,7 @@
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/backend/nodes/copyfuncs.c,v 1.430 2009/04/16 20:42:16 tgl Exp $
* $PostgreSQL: pgsql/src/backend/nodes/copyfuncs.c,v 1.431 2009/06/11 14:48:58 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@ -182,7 +182,7 @@ _copyAppend(Append *from)
static RecursiveUnion *
_copyRecursiveUnion(RecursiveUnion *from)
{
RecursiveUnion *newnode = makeNode(RecursiveUnion);
RecursiveUnion *newnode = makeNode(RecursiveUnion);
/*
* copy node superclass fields
@ -455,7 +455,7 @@ _copyValuesScan(ValuesScan *from)
static CteScan *
_copyCteScan(CteScan *from)
{
CteScan *newnode = makeNode(CteScan);
CteScan *newnode = makeNode(CteScan);
/*
* copy node superclass fields
@ -1916,7 +1916,7 @@ _copyFuncCall(FuncCall *from)
static A_Star *
_copyAStar(A_Star *from)
{
A_Star *newnode = makeNode(A_Star);
A_Star *newnode = makeNode(A_Star);
return newnode;
}
@ -1946,7 +1946,7 @@ _copyA_Indirection(A_Indirection *from)
static A_ArrayExpr *
_copyA_ArrayExpr(A_ArrayExpr *from)
{
A_ArrayExpr *newnode = makeNode(A_ArrayExpr);
A_ArrayExpr *newnode = makeNode(A_ArrayExpr);
COPY_NODE_FIELD(elements);
COPY_LOCATION_FIELD(location);
@ -2382,7 +2382,7 @@ _copyClusterStmt(ClusterStmt *from)
COPY_NODE_FIELD(relation);
COPY_STRING_FIELD(indexname);
COPY_SCALAR_FIELD(verbose) ;
COPY_SCALAR_FIELD(verbose);
return newnode;
}

View File

@ -22,7 +22,7 @@
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/backend/nodes/equalfuncs.c,v 1.353 2009/04/16 20:42:16 tgl Exp $
* $PostgreSQL: pgsql/src/backend/nodes/equalfuncs.c,v 1.354 2009/06/11 14:48:58 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@ -773,9 +773,9 @@ static bool
_equalPlaceHolderVar(PlaceHolderVar *a, PlaceHolderVar *b)
{
/*
* We intentionally do not compare phexpr. Two PlaceHolderVars with the
* We intentionally do not compare phexpr. Two PlaceHolderVars with the
* same ID and levelsup should be considered equal even if the contained
* expressions have managed to mutate to different states. One way in
* expressions have managed to mutate to different states. One way in
* which that can happen is that initplan sublinks would get replaced by
* differently-numbered Params when sublink folding is done. (The end
* result of such a situation would be some unreferenced initplans, which

View File

@ -9,7 +9,7 @@
*
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/backend/nodes/list.c,v 1.71 2009/01/01 17:23:43 momjian Exp $
* $PostgreSQL: pgsql/src/backend/nodes/list.c,v 1.72 2009/06/11 14:48:58 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@ -793,7 +793,7 @@ list_union_oid(List *list1, List *list2)
* "intersection" if list1 is known unique beforehand.
*
* This variant works on lists of pointers, and determines list
* membership via equal(). Note that the list1 member will be pointed
* membership via equal(). Note that the list1 member will be pointed
* to in the result.
*/
List *

View File

@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/backend/nodes/nodeFuncs.c,v 1.39 2009/03/10 22:09:25 tgl Exp $
* $PostgreSQL: pgsql/src/backend/nodes/nodeFuncs.c,v 1.40 2009/06/11 14:48:58 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@ -231,7 +231,7 @@ exprType(Node *expr)
/*
* exprTypmod -
* returns the type-specific modifier of the expression's result type,
* if it can be determined. In many cases, it can't and we return -1.
* if it can be determined. In many cases, it can't and we return -1.
*/
int32
exprTypmod(Node *expr)
@ -680,7 +680,7 @@ exprLocation(Node *expr)
case T_DistinctExpr: /* struct-equivalent to OpExpr */
case T_NullIfExpr: /* struct-equivalent to OpExpr */
{
OpExpr *opexpr = (OpExpr *) expr;
OpExpr *opexpr = (OpExpr *) expr;
/* consider both operator name and leftmost arg */
loc = leftmostLoc(opexpr->location,
@ -711,7 +711,7 @@ exprLocation(Node *expr)
break;
case T_SubLink:
{
SubLink *sublink = (SubLink *) expr;
SubLink *sublink = (SubLink *) expr;
/* check the testexpr, if any, and the operator/keyword */
loc = leftmostLoc(exprLocation(sublink->testexpr),
@ -792,7 +792,7 @@ exprLocation(Node *expr)
break;
case T_XmlExpr:
{
XmlExpr *xexpr = (XmlExpr *) expr;
XmlExpr *xexpr = (XmlExpr *) expr;
/* consider both function name and leftmost arg */
loc = leftmostLoc(xexpr->location,
@ -846,7 +846,7 @@ exprLocation(Node *expr)
break;
case T_A_Expr:
{
A_Expr *aexpr = (A_Expr *) expr;
A_Expr *aexpr = (A_Expr *) expr;
/* use leftmost of operator or left operand (if any) */
/* we assume right operand can't be to left of operator */
@ -865,7 +865,7 @@ exprLocation(Node *expr)
break;
case T_FuncCall:
{
FuncCall *fc = (FuncCall *) expr;
FuncCall *fc = (FuncCall *) expr;
/* consider both function name and leftmost arg */
loc = leftmostLoc(fc->location,
@ -882,11 +882,11 @@ exprLocation(Node *expr)
break;
case T_TypeCast:
{
TypeCast *tc = (TypeCast *) expr;
TypeCast *tc = (TypeCast *) expr;
/*
* This could represent CAST(), ::, or TypeName 'literal',
* so any of the components might be leftmost.
* This could represent CAST(), ::, or TypeName 'literal', so
* any of the components might be leftmost.
*/
loc = exprLocation(tc->arg);
loc = leftmostLoc(loc, tc->typename->location);
@ -1265,7 +1265,7 @@ expression_tree_walker(Node *node,
break;
case T_WindowClause:
{
WindowClause *wc = (WindowClause *) node;
WindowClause *wc = (WindowClause *) node;
if (walker(wc->partitionClause, context))
return true;
@ -1278,8 +1278,8 @@ expression_tree_walker(Node *node,
CommonTableExpr *cte = (CommonTableExpr *) node;
/*
* Invoke the walker on the CTE's Query node, so it
* can recurse into the sub-query if it wants to.
* Invoke the walker on the CTE's Query node, so it can
* recurse into the sub-query if it wants to.
*/
return walker(cte->ctequery, context);
}
@ -1423,7 +1423,7 @@ range_table_walker(List *rtable,
{
case RTE_RELATION:
case RTE_SPECIAL:
case RTE_CTE:
case RTE_CTE:
/* nothing to do */
break;
case RTE_SUBQUERY:
@ -1904,8 +1904,8 @@ expression_tree_mutator(Node *node,
return node;
case T_WindowClause:
{
WindowClause *wc = (WindowClause *) node;
WindowClause *newnode;
WindowClause *wc = (WindowClause *) node;
WindowClause *newnode;
FLATCOPY(newnode, wc, WindowClause);
MUTATE(newnode->partitionClause, wc->partitionClause, List *);
@ -1921,8 +1921,8 @@ expression_tree_mutator(Node *node,
FLATCOPY(newnode, cte, CommonTableExpr);
/*
* Also invoke the mutator on the CTE's Query node, so it
* can recurse into the sub-query if it wants to.
* Also invoke the mutator on the CTE's Query node, so it can
* recurse into the sub-query if it wants to.
*/
MUTATE(newnode->ctequery, cte->ctequery, Node *);
return (Node *) newnode;
@ -2070,7 +2070,7 @@ query_tree_mutator(Query *query,
MUTATE(query->limitCount, query->limitCount, Node *);
if (!(flags & QTW_IGNORE_CTE_SUBQUERIES))
MUTATE(query->cteList, query->cteList, List *);
else /* else copy CTE list as-is */
else /* else copy CTE list as-is */
query->cteList = copyObject(query->cteList);
query->rtable = range_table_mutator(query->rtable,
mutator, context, flags);
@ -2198,7 +2198,7 @@ query_or_expression_tree_mutator(Node *node,
* that could appear under it, but not other statement types.
*/
bool
raw_expression_tree_walker(Node *node, bool (*walker) (), void *context)
raw_expression_tree_walker(Node *node, bool (*walker) (), void *context)
{
ListCell *temp;
@ -2356,7 +2356,7 @@ raw_expression_tree_walker(Node *node, bool (*walker) (), void *context)
break;
case T_A_Expr:
{
A_Expr *expr = (A_Expr *) node;
A_Expr *expr = (A_Expr *) node;
if (walker(expr->lexpr, context))
return true;
@ -2370,7 +2370,7 @@ raw_expression_tree_walker(Node *node, bool (*walker) (), void *context)
break;
case T_FuncCall:
{
FuncCall *fcall = (FuncCall *) node;
FuncCall *fcall = (FuncCall *) node;
if (walker(fcall->args, context))
return true;
@ -2381,7 +2381,7 @@ raw_expression_tree_walker(Node *node, bool (*walker) (), void *context)
break;
case T_A_Indices:
{
A_Indices *indices = (A_Indices *) node;
A_Indices *indices = (A_Indices *) node;
if (walker(indices->lidx, context))
return true;
@ -2403,7 +2403,7 @@ raw_expression_tree_walker(Node *node, bool (*walker) (), void *context)
return walker(((A_ArrayExpr *) node)->elements, context);
case T_ResTarget:
{
ResTarget *rt = (ResTarget *) node;
ResTarget *rt = (ResTarget *) node;
if (walker(rt->indirection, context))
return true;
@ -2413,7 +2413,7 @@ raw_expression_tree_walker(Node *node, bool (*walker) (), void *context)
break;
case T_TypeCast:
{
TypeCast *tc = (TypeCast *) node;
TypeCast *tc = (TypeCast *) node;
if (walker(tc->arg, context))
return true;
@ -2425,7 +2425,7 @@ raw_expression_tree_walker(Node *node, bool (*walker) (), void *context)
return walker(((SortBy *) node)->node, context);
case T_WindowDef:
{
WindowDef *wd = (WindowDef *) node;
WindowDef *wd = (WindowDef *) node;
if (walker(wd->partitionClause, context))
return true;
@ -2455,7 +2455,7 @@ raw_expression_tree_walker(Node *node, bool (*walker) (), void *context)
break;
case T_TypeName:
{
TypeName *tn = (TypeName *) node;
TypeName *tn = (TypeName *) node;
if (walker(tn->typmods, context))
return true;
@ -2466,7 +2466,7 @@ raw_expression_tree_walker(Node *node, bool (*walker) (), void *context)
break;
case T_ColumnDef:
{
ColumnDef *coldef = (ColumnDef *) node;
ColumnDef *coldef = (ColumnDef *) node;
if (walker(coldef->typename, context))
return true;

View File

@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/backend/nodes/outfuncs.c,v 1.359 2009/04/16 20:42:16 tgl Exp $
* $PostgreSQL: pgsql/src/backend/nodes/outfuncs.c,v 1.360 2009/06/11 14:48:58 momjian Exp $
*
* NOTES
* Every node type that can appear in stored rules' parsetrees *must*
@ -332,7 +332,7 @@ _outAppend(StringInfo str, Append *node)
static void
_outRecursiveUnion(StringInfo str, RecursiveUnion *node)
{
int i;
int i;
WRITE_NODE_TYPE("RECURSIVEUNION");
@ -544,7 +544,7 @@ _outHashJoin(StringInfo str, HashJoin *node)
static void
_outAgg(StringInfo str, Agg *node)
{
int i;
int i;
WRITE_NODE_TYPE("AGG");
@ -587,7 +587,7 @@ _outWindowAgg(StringInfo str, WindowAgg *node)
WRITE_INT_FIELD(ordNumCols);
appendStringInfo(str, " :ordColIdx");
for (i = 0; i< node->ordNumCols; i++)
for (i = 0; i < node->ordNumCols; i++)
appendStringInfo(str, " %d", node->ordColIdx[i]);
appendStringInfo(str, " :ordOperations");

View File

@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/backend/nodes/readfuncs.c,v 1.221 2009/01/22 20:16:04 tgl Exp $
* $PostgreSQL: pgsql/src/backend/nodes/readfuncs.c,v 1.222 2009/06/11 14:48:58 momjian Exp $
*
* NOTES
* Path and Plan nodes do not have any readfuncs support, because we
@ -107,7 +107,7 @@
#define READ_LOCATION_FIELD(fldname) \
token = pg_strtok(&length); /* skip :fldname */ \
token = pg_strtok(&length); /* get field value */ \
local_node->fldname = -1 /* set field to "unknown" */
local_node->fldname = -1 /* set field to "unknown" */
/* Read a Node field */
#define READ_NODE_FIELD(fldname) \
@ -148,7 +148,8 @@ static Datum readDatum(bool typbyval);
static Bitmapset *
_readBitmapset(void)
{
Bitmapset *result = NULL;
Bitmapset *result = NULL;
READ_TEMP_LOCALS();
token = pg_strtok(&length);
@ -165,8 +166,8 @@ _readBitmapset(void)
for (;;)
{
int val;
char *endptr;
int val;
char *endptr;
token = pg_strtok(&length);
if (token == NULL)

View File

@ -19,7 +19,7 @@
* of lossiness. In theory we could fall back to page ranges at some
* point, but for now that seems useless complexity.
*
* We also support the notion of candidate matches, or rechecking. This
* We also support the notion of candidate matches, or rechecking. This
* means we know that a search need visit only some tuples on a page,
* but we are not certain that all of those tuples are real matches.
* So the eventual heap scan must recheck the quals for these tuples only,
@ -32,7 +32,7 @@
* Copyright (c) 2003-2009, PostgreSQL Global Development Group
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/backend/nodes/tidbitmap.c,v 1.18 2009/03/24 20:17:14 tgl Exp $
* $PostgreSQL: pgsql/src/backend/nodes/tidbitmap.c,v 1.19 2009/06/11 14:48:58 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@ -143,7 +143,7 @@ struct TIDBitmap
/*
* When iterating over a bitmap in sorted order, a TBMIterator is used to
* track our progress. There can be several iterators scanning the same
* track our progress. There can be several iterators scanning the same
* bitmap concurrently. Note that the bitmap becomes read-only as soon as
* any iterator is created.
*/
@ -511,10 +511,10 @@ tbm_intersect_page(TIDBitmap *a, PagetableEntry *apage, const TIDBitmap *b)
else if (tbm_page_is_lossy(b, apage->blockno))
{
/*
* Some of the tuples in 'a' might not satisfy the quals for 'b',
* but because the page 'b' is lossy, we don't know which ones.
* Therefore we mark 'a' as requiring rechecks, to indicate that
* at most those tuples set in 'a' are matches.
* Some of the tuples in 'a' might not satisfy the quals for 'b', but
* because the page 'b' is lossy, we don't know which ones. Therefore
* we mark 'a' as requiring rechecks, to indicate that at most those
* tuples set in 'a' are matches.
*/
apage->recheck = true;
return false;
@ -573,7 +573,7 @@ tbm_begin_iterate(TIDBitmap *tbm)
* needs of the TBMIterateResult sub-struct.
*/
iterator = (TBMIterator *) palloc(sizeof(TBMIterator) +
MAX_TUPLES_PER_PAGE * sizeof(OffsetNumber));
MAX_TUPLES_PER_PAGE * sizeof(OffsetNumber));
iterator->tbm = tbm;
/*
@ -584,10 +584,10 @@ tbm_begin_iterate(TIDBitmap *tbm)
iterator->schunkbit = 0;
/*
* If we have a hashtable, create and fill the sorted page lists,
* unless we already did that for a previous iterator. Note that the
* lists are attached to the bitmap not the iterator, so they can be
* used by more than one iterator.
* If we have a hashtable, create and fill the sorted page lists, unless
* we already did that for a previous iterator. Note that the lists are
* attached to the bitmap not the iterator, so they can be used by more
* than one iterator.
*/
if (tbm->status == TBM_HASH && !tbm->iterating)
{
@ -644,7 +644,7 @@ tbm_begin_iterate(TIDBitmap *tbm)
TBMIterateResult *
tbm_iterate(TBMIterator *iterator)
{
TIDBitmap *tbm = iterator->tbm;
TIDBitmap *tbm = iterator->tbm;
TBMIterateResult *output = &(iterator->output);
Assert(tbm->iterating);