mirror of
https://github.com/postgres/postgres.git
synced 2025-08-21 10:42:50 +03:00
Initial pgindent run for v12.
This is still using the 2.0 version of pg_bsd_indent. I thought it would be good to commit this separately, so as to document the differences between 2.0 and 2.1 behavior. Discussion: https://postgr.es/m/16296.1558103386@sss.pgh.pa.us
This commit is contained in:
@@ -216,7 +216,7 @@ typedef struct IndexAmRoutine
|
||||
amcostestimate_function amcostestimate;
|
||||
amoptions_function amoptions;
|
||||
amproperty_function amproperty; /* can be NULL */
|
||||
ambuildphasename_function ambuildphasename; /* can be NULL */
|
||||
ambuildphasename_function ambuildphasename; /* can be NULL */
|
||||
amvalidate_function amvalidate;
|
||||
ambeginscan_function ambeginscan;
|
||||
amrescan_function amrescan;
|
||||
|
@@ -18,9 +18,10 @@
|
||||
#include "lib/stringinfo.h"
|
||||
|
||||
#define XLOG_GIST_PAGE_UPDATE 0x00
|
||||
#define XLOG_GIST_DELETE 0x10 /* delete leaf index tuples for a page */
|
||||
#define XLOG_GIST_PAGE_REUSE 0x20 /* old page is about to be reused from
|
||||
* FSM */
|
||||
#define XLOG_GIST_DELETE 0x10 /* delete leaf index tuples for a
|
||||
* page */
|
||||
#define XLOG_GIST_PAGE_REUSE 0x20 /* old page is about to be reused
|
||||
* from FSM */
|
||||
#define XLOG_GIST_PAGE_SPLIT 0x30
|
||||
/* #define XLOG_GIST_INSERT_COMPLETE 0x40 */ /* not used anymore */
|
||||
/* #define XLOG_GIST_CREATE_INDEX 0x50 */ /* not used anymore */
|
||||
@@ -83,7 +84,8 @@ typedef struct gistxlogPageSplit
|
||||
typedef struct gistxlogPageDelete
|
||||
{
|
||||
TransactionId deleteXid; /* last Xid which could see page in scan */
|
||||
OffsetNumber downlinkOffset; /* Offset of downlink referencing this page */
|
||||
OffsetNumber downlinkOffset; /* Offset of downlink referencing this
|
||||
* page */
|
||||
} gistxlogPageDelete;
|
||||
|
||||
#define SizeOfGistxlogPageDelete (offsetof(gistxlogPageDelete, downlinkOffset) + sizeof(OffsetNumber))
|
||||
|
@@ -31,7 +31,7 @@ typedef struct BulkInsertStateData
|
||||
{
|
||||
BufferAccessStrategy strategy; /* our BULKWRITE strategy object */
|
||||
Buffer current_buf; /* current insertion target page */
|
||||
} BulkInsertStateData;
|
||||
} BulkInsertStateData;
|
||||
|
||||
|
||||
extern void RelationPutHeapTuple(Relation relation, Buffer buffer,
|
||||
|
@@ -78,7 +78,7 @@ typedef struct ParallelBlockTableScanDescData
|
||||
BlockNumber phs_startblock; /* starting block number */
|
||||
pg_atomic_uint64 phs_nallocated; /* number of blocks allocated to
|
||||
* workers so far. */
|
||||
} ParallelBlockTableScanDescData;
|
||||
} ParallelBlockTableScanDescData;
|
||||
typedef struct ParallelBlockTableScanDescData *ParallelBlockTableScanDesc;
|
||||
|
||||
/*
|
||||
|
@@ -146,7 +146,7 @@ typedef struct SpGistSearchItem
|
||||
|
||||
/* array with numberOfOrderBys entries */
|
||||
double distances[FLEXIBLE_ARRAY_MEMBER];
|
||||
} SpGistSearchItem;
|
||||
} SpGistSearchItem;
|
||||
|
||||
#define SizeOfSpGistSearchItem(n_distances) \
|
||||
(offsetof(SpGistSearchItem, distances) + sizeof(double) * (n_distances))
|
||||
|
@@ -18,7 +18,7 @@
|
||||
#include "storage/off.h"
|
||||
|
||||
/* XLOG record types for SPGiST */
|
||||
/* #define XLOG_SPGIST_CREATE_INDEX 0x00 */ /* not used anymore */
|
||||
/* #define XLOG_SPGIST_CREATE_INDEX 0x00 */ /* not used anymore */
|
||||
#define XLOG_SPGIST_ADD_LEAF 0x10
|
||||
#define XLOG_SPGIST_MOVE_LEAFS 0x20
|
||||
#define XLOG_SPGIST_ADD_NODE 0x30
|
||||
|
@@ -45,21 +45,21 @@ struct ValidateIndexState;
|
||||
typedef enum ScanOptions
|
||||
{
|
||||
/* one of SO_TYPE_* may be specified */
|
||||
SO_TYPE_SEQSCAN = 1 << 0,
|
||||
SO_TYPE_BITMAPSCAN = 1 << 1,
|
||||
SO_TYPE_SAMPLESCAN = 1 << 2,
|
||||
SO_TYPE_ANALYZE = 1 << 3,
|
||||
SO_TYPE_SEQSCAN = 1 << 0,
|
||||
SO_TYPE_BITMAPSCAN = 1 << 1,
|
||||
SO_TYPE_SAMPLESCAN = 1 << 2,
|
||||
SO_TYPE_ANALYZE = 1 << 3,
|
||||
|
||||
/* several of SO_ALLOW_* may be specified */
|
||||
/* allow or disallow use of access strategy */
|
||||
SO_ALLOW_STRAT = 1 << 4,
|
||||
SO_ALLOW_STRAT = 1 << 4,
|
||||
/* report location to syncscan logic? */
|
||||
SO_ALLOW_SYNC = 1 << 5,
|
||||
SO_ALLOW_SYNC = 1 << 5,
|
||||
/* verify visibility page-at-a-time? */
|
||||
SO_ALLOW_PAGEMODE = 1 << 6,
|
||||
SO_ALLOW_PAGEMODE = 1 << 6,
|
||||
|
||||
/* unregister snapshot at scan end? */
|
||||
SO_TEMP_SNAPSHOT = 1 << 7
|
||||
SO_TEMP_SNAPSHOT = 1 << 7
|
||||
} ScanOptions;
|
||||
|
||||
/*
|
||||
@@ -575,12 +575,12 @@ typedef struct TableAmRoutine
|
||||
|
||||
/*
|
||||
* This callback should return true if the relation requires a TOAST table
|
||||
* and false if it does not. It may wish to examine the relation's
|
||||
* tuple descriptor before making a decision, but if it uses some other
|
||||
* method of storing large values (or if it does not support them) it can
|
||||
* simply return false.
|
||||
* and false if it does not. It may wish to examine the relation's tuple
|
||||
* descriptor before making a decision, but if it uses some other method
|
||||
* of storing large values (or if it does not support them) it can simply
|
||||
* return false.
|
||||
*/
|
||||
bool (*relation_needs_toast_table) (Relation rel);
|
||||
bool (*relation_needs_toast_table) (Relation rel);
|
||||
|
||||
|
||||
/* ------------------------------------------------------------------------
|
||||
@@ -738,7 +738,7 @@ table_beginscan(Relation rel, Snapshot snapshot,
|
||||
int nkeys, struct ScanKeyData *key)
|
||||
{
|
||||
uint32 flags = SO_TYPE_SEQSCAN |
|
||||
SO_ALLOW_STRAT | SO_ALLOW_SYNC | SO_ALLOW_PAGEMODE;
|
||||
SO_ALLOW_STRAT | SO_ALLOW_SYNC | SO_ALLOW_PAGEMODE;
|
||||
|
||||
return rel->rd_tableam->scan_begin(rel, snapshot, nkeys, key, NULL, flags);
|
||||
}
|
||||
|
@@ -38,7 +38,7 @@ typedef struct TupleConstr
|
||||
{
|
||||
AttrDefault *defval; /* array */
|
||||
ConstrCheck *check; /* array */
|
||||
struct AttrMissing *missing; /* missing attributes values, NULL if none */
|
||||
struct AttrMissing *missing; /* missing attributes values, NULL if none */
|
||||
uint16 num_defval;
|
||||
uint16 num_check;
|
||||
bool has_not_null;
|
||||
@@ -85,7 +85,7 @@ typedef struct TupleDescData
|
||||
TupleConstr *constr; /* constraints, or NULL if none */
|
||||
/* attrs[N] is the description of Attribute Number N+1 */
|
||||
FormData_pg_attribute attrs[FLEXIBLE_ARRAY_MEMBER];
|
||||
} TupleDescData;
|
||||
} TupleDescData;
|
||||
typedef struct TupleDescData *TupleDesc;
|
||||
|
||||
/* Accessor for the i'th attribute of tupdesc. */
|
||||
|
@@ -95,7 +95,7 @@ typedef enum
|
||||
RECOVERY_TARGET_TIMELINE_CONTROLFILE,
|
||||
RECOVERY_TARGET_TIMELINE_LATEST,
|
||||
RECOVERY_TARGET_TIMELINE_NUMERIC
|
||||
} RecoveryTargetTimeLineGoal;
|
||||
} RecoveryTargetTimeLineGoal;
|
||||
|
||||
extern XLogRecPtr ProcLastRecPtr;
|
||||
extern XLogRecPtr XactLastRecEnd;
|
||||
|
@@ -268,7 +268,7 @@ typedef enum
|
||||
RECOVERY_TARGET_ACTION_PAUSE,
|
||||
RECOVERY_TARGET_ACTION_PROMOTE,
|
||||
RECOVERY_TARGET_ACTION_SHUTDOWN
|
||||
} RecoveryTargetAction;
|
||||
} RecoveryTargetAction;
|
||||
|
||||
/*
|
||||
* Method table for resource managers.
|
||||
|
Reference in New Issue
Block a user