diff options
| author | Pavan Deolasee | 2017-06-27 11:23:19 +0000 |
|---|---|---|
| committer | Pavan Deolasee | 2017-06-27 11:23:19 +0000 |
| commit | e3e1c61e5ee9facf3b0a9bd6a0ce79da7011f9f2 (patch) | |
| tree | cad4a0509c9ac54e260ba922b90b086804bad2d4 /src/include | |
| parent | 668079ca5792a23fc0e220750bff51bb0558b4a5 (diff) | |
| parent | 2710ccd782d0308a3fa1ab193531183148e9b626 (diff) | |
Merge PG10 master branch into xl10devel
This commit merges PG10 branch upto commit
2710ccd782d0308a3fa1ab193531183148e9b626. Regression tests show no noteworthy
additional failures. This merge includes major pgindent work done with the
newer version of pgindent
Diffstat (limited to 'src/include')
554 files changed, 1776 insertions, 1771 deletions
diff --git a/src/include/access/amapi.h b/src/include/access/amapi.h index f919cf8b87..0db4fc73ac 100644 --- a/src/include/access/amapi.h +++ b/src/include/access/amapi.h @@ -60,75 +60,75 @@ typedef enum IndexAMProperty /* build new index */ typedef IndexBuildResult *(*ambuild_function) (Relation heapRelation, - Relation indexRelation, - struct IndexInfo *indexInfo); + Relation indexRelation, + struct IndexInfo *indexInfo); /* build empty index */ typedef void (*ambuildempty_function) (Relation indexRelation); /* insert this tuple */ typedef bool (*aminsert_function) (Relation indexRelation, - Datum *values, - bool *isnull, - ItemPointer heap_tid, - Relation heapRelation, - IndexUniqueCheck checkUnique, - struct IndexInfo *indexInfo); + Datum *values, + bool *isnull, + ItemPointer heap_tid, + Relation heapRelation, + IndexUniqueCheck checkUnique, + struct IndexInfo *indexInfo); /* bulk delete */ typedef IndexBulkDeleteResult *(*ambulkdelete_function) (IndexVacuumInfo *info, - IndexBulkDeleteResult *stats, - IndexBulkDeleteCallback callback, - void *callback_state); + IndexBulkDeleteResult *stats, + IndexBulkDeleteCallback callback, + void *callback_state); /* post-VACUUM cleanup */ typedef IndexBulkDeleteResult *(*amvacuumcleanup_function) (IndexVacuumInfo *info, - IndexBulkDeleteResult *stats); + IndexBulkDeleteResult *stats); /* can indexscan return IndexTuples? */ typedef bool (*amcanreturn_function) (Relation indexRelation, int attno); /* estimate cost of an indexscan */ typedef void (*amcostestimate_function) (struct PlannerInfo *root, - struct IndexPath *path, - double loop_count, - Cost *indexStartupCost, - Cost *indexTotalCost, - Selectivity *indexSelectivity, - double *indexCorrelation, - double *indexPages); + struct IndexPath *path, + double loop_count, + Cost *indexStartupCost, + Cost *indexTotalCost, + Selectivity *indexSelectivity, + double *indexCorrelation, + double *indexPages); /* parse index reloptions */ typedef bytea *(*amoptions_function) (Datum reloptions, - bool validate); + bool validate); /* report AM, index, or index column property */ typedef bool (*amproperty_function) (Oid index_oid, int attno, - IndexAMProperty prop, const char *propname, - bool *res, bool *isnull); + IndexAMProperty prop, const char *propname, + bool *res, bool *isnull); /* validate definition of an opclass for this AM */ typedef bool (*amvalidate_function) (Oid opclassoid); /* prepare for index scan */ typedef IndexScanDesc (*ambeginscan_function) (Relation indexRelation, - int nkeys, - int norderbys); + int nkeys, + int norderbys); /* (re)start index scan */ typedef void (*amrescan_function) (IndexScanDesc scan, - ScanKey keys, - int nkeys, - ScanKey orderbys, - int norderbys); + ScanKey keys, + int nkeys, + ScanKey orderbys, + int norderbys); /* next valid tuple */ typedef bool (*amgettuple_function) (IndexScanDesc scan, - ScanDirection direction); + ScanDirection direction); /* fetch all valid tuples */ typedef int64 (*amgetbitmap_function) (IndexScanDesc scan, - TIDBitmap *tbm); + TIDBitmap *tbm); /* end index scan */ typedef void (*amendscan_function) (IndexScanDesc scan); @@ -203,19 +203,19 @@ typedef struct IndexAmRoutine amcanreturn_function amcanreturn; /* can be NULL */ amcostestimate_function amcostestimate; amoptions_function amoptions; - amproperty_function amproperty; /* can be NULL */ + amproperty_function amproperty; /* can be NULL */ amvalidate_function amvalidate; ambeginscan_function ambeginscan; amrescan_function amrescan; - amgettuple_function amgettuple; /* can be NULL */ + amgettuple_function amgettuple; /* can be NULL */ amgetbitmap_function amgetbitmap; /* can be NULL */ amendscan_function amendscan; - ammarkpos_function ammarkpos; /* can be NULL */ - amrestrpos_function amrestrpos; /* can be NULL */ + ammarkpos_function ammarkpos; /* can be NULL */ + amrestrpos_function amrestrpos; /* can be NULL */ /* interface functions to support parallel index scans */ - amestimateparallelscan_function amestimateparallelscan; /* can be NULL */ - aminitparallelscan_function aminitparallelscan; /* can be NULL */ + amestimateparallelscan_function amestimateparallelscan; /* can be NULL */ + aminitparallelscan_function aminitparallelscan; /* can be NULL */ amparallelrescan_function amparallelrescan; /* can be NULL */ } IndexAmRoutine; @@ -224,4 +224,4 @@ typedef struct IndexAmRoutine extern IndexAmRoutine *GetIndexAmRoutine(Oid amhandler); extern IndexAmRoutine *GetIndexAmRoutineByAmId(Oid amoid, bool noerror); -#endif /* AMAPI_H */ +#endif /* AMAPI_H */ diff --git a/src/include/access/amvalidate.h b/src/include/access/amvalidate.h index 742c25a78d..04b7429a78 100644 --- a/src/include/access/amvalidate.h +++ b/src/include/access/amvalidate.h @@ -33,4 +33,4 @@ extern bool check_amop_signature(Oid opno, Oid restype, Oid lefttype, Oid righttype); extern bool opfamily_can_sort_type(Oid opfamilyoid, Oid datatypeoid); -#endif /* AMVALIDATE_H */ +#endif /* AMVALIDATE_H */ diff --git a/src/include/access/attnum.h b/src/include/access/attnum.h index 7fa459fc8c..d23888b098 100644 --- a/src/include/access/attnum.h +++ b/src/include/access/attnum.h @@ -61,4 +61,4 @@ typedef int16 AttrNumber; #define AttrOffsetGetAttrNumber(attributeOffset) \ ((AttrNumber) (1 + (attributeOffset))) -#endif /* ATTNUM_H */ +#endif /* ATTNUM_H */ diff --git a/src/include/access/brin.h b/src/include/access/brin.h index 45d55a9733..61a38804ca 100644 --- a/src/include/access/brin.h +++ b/src/include/access/brin.h @@ -49,4 +49,4 @@ typedef struct BrinStatsData extern void brinGetStats(Relation index, BrinStatsData *stats); -#endif /* BRIN_H */ +#endif /* BRIN_H */ diff --git a/src/include/access/brin_internal.h b/src/include/access/brin_internal.h index abe887788b..3ed67438b2 100644 --- a/src/include/access/brin_internal.h +++ b/src/include/access/brin_internal.h @@ -107,4 +107,4 @@ extern bytea *brinoptions(Datum reloptions, bool validate); /* brin_validate.c */ extern bool brinvalidate(Oid opclassoid); -#endif /* BRIN_INTERNAL_H */ +#endif /* BRIN_INTERNAL_H */ diff --git a/src/include/access/brin_page.h b/src/include/access/brin_page.h index e2b3b92fac..bf03a6e9f8 100644 --- a/src/include/access/brin_page.h +++ b/src/include/access/brin_page.h @@ -93,4 +93,4 @@ typedef struct RevmapContents #define REVMAP_PAGE_MAXITEMS \ (REVMAP_CONTENT_SIZE / sizeof(ItemPointerData)) -#endif /* BRIN_PAGE_H */ +#endif /* BRIN_PAGE_H */ diff --git a/src/include/access/brin_pageops.h b/src/include/access/brin_pageops.h index ab38093a23..e0f5641635 100644 --- a/src/include/access/brin_pageops.h +++ b/src/include/access/brin_pageops.h @@ -35,4 +35,4 @@ extern void brin_evacuate_page(Relation idxRel, BlockNumber pagesPerRange, extern bool brin_page_cleanup(Relation idxrel, Buffer buf); -#endif /* BRIN_PAGEOPS_H */ +#endif /* BRIN_PAGEOPS_H */ diff --git a/src/include/access/brin_revmap.h b/src/include/access/brin_revmap.h index 7fdcf877f4..ddd87e040b 100644 --- a/src/include/access/brin_revmap.h +++ b/src/include/access/brin_revmap.h @@ -38,4 +38,4 @@ extern BrinTuple *brinGetTupleForHeapBlock(BrinRevmap *revmap, Size *size, int mode, Snapshot snapshot); extern bool brinRevmapDesummarizeRange(Relation idxrel, BlockNumber heapBlk); -#endif /* BRIN_REVMAP_H */ +#endif /* BRIN_REVMAP_H */ diff --git a/src/include/access/brin_tuple.h b/src/include/access/brin_tuple.h index 3f4a7b6d3c..6545c0a6ff 100644 --- a/src/include/access/brin_tuple.h +++ b/src/include/access/brin_tuple.h @@ -99,4 +99,4 @@ extern BrinMemTuple *brin_memtuple_initialize(BrinMemTuple *dtuple, extern BrinMemTuple *brin_deform_tuple(BrinDesc *brdesc, BrinTuple *tuple, BrinMemTuple *dMemtuple); -#endif /* BRIN_TUPLE_H */ +#endif /* BRIN_TUPLE_H */ diff --git a/src/include/access/brin_xlog.h b/src/include/access/brin_xlog.h index 38e6dcccf2..10e90d3c78 100644 --- a/src/include/access/brin_xlog.h +++ b/src/include/access/brin_xlog.h @@ -148,4 +148,4 @@ extern void brin_desc(StringInfo buf, XLogReaderState *record); extern const char *brin_identify(uint8 info); extern void brin_mask(char *pagedata, BlockNumber blkno); -#endif /* BRIN_XLOG_H */ +#endif /* BRIN_XLOG_H */ diff --git a/src/include/access/clog.h b/src/include/access/clog.h index 5ac7cdd618..7bae0902b5 100644 --- a/src/include/access/clog.h +++ b/src/include/access/clog.h @@ -36,7 +36,7 @@ typedef struct xl_clog_truncate } xl_clog_truncate; extern void TransactionIdSetTreeStatus(TransactionId xid, int nsubxids, - TransactionId *subxids, XidStatus status, XLogRecPtr lsn); + TransactionId *subxids, XidStatus status, XLogRecPtr lsn); extern XidStatus TransactionIdGetStatus(TransactionId xid, XLogRecPtr *lsn); extern Size CLOGShmemBuffers(void); @@ -58,4 +58,4 @@ extern void clog_redo(XLogReaderState *record); extern void clog_desc(StringInfo buf, XLogReaderState *record); extern const char *clog_identify(uint8 info); -#endif /* CLOG_H */ +#endif /* CLOG_H */ diff --git a/src/include/access/commit_ts.h b/src/include/access/commit_ts.h index f172c91d8f..31936faf08 100644 --- a/src/include/access/commit_ts.h +++ b/src/include/access/commit_ts.h @@ -74,4 +74,4 @@ extern void commit_ts_redo(XLogReaderState *record); extern void commit_ts_desc(StringInfo buf, XLogReaderState *record); extern const char *commit_ts_identify(uint8 info); -#endif /* COMMIT_TS_H */ +#endif /* COMMIT_TS_H */ diff --git a/src/include/access/genam.h b/src/include/access/genam.h index f467b18a9c..b56a44f902 100644 --- a/src/include/access/genam.h +++ b/src/include/access/genam.h @@ -48,7 +48,7 @@ typedef struct IndexVacuumInfo bool estimated_count; /* num_heap_tuples is an estimate */ int message_level; /* ereport level for progress messages */ double num_heap_tuples; /* tuples remaining in heap */ - BufferAccessStrategy strategy; /* access strategy for reads */ + BufferAccessStrategy strategy; /* access strategy for reads */ } IndexVacuumInfo; /* @@ -73,7 +73,7 @@ typedef struct IndexBulkDeleteResult BlockNumber num_pages; /* pages remaining in index */ BlockNumber pages_removed; /* # removed during vacuum operation */ bool estimated_count; /* num_index_tuples is an estimate */ - double num_index_tuples; /* tuples remaining */ + double num_index_tuples; /* tuples remaining */ double tuples_removed; /* # removed during vacuum operation */ BlockNumber pages_deleted; /* # unused pages in index */ BlockNumber pages_free; /* # pages available for reuse */ @@ -152,7 +152,7 @@ extern void index_markpos(IndexScanDesc scan); extern void index_restrpos(IndexScanDesc scan); extern Size index_parallelscan_estimate(Relation indexrel, Snapshot snapshot); extern void index_parallelscan_initialize(Relation heaprel, Relation indexrel, - Snapshot snapshot, ParallelIndexScanDesc target); + Snapshot snapshot, ParallelIndexScanDesc target); extern void index_parallelrescan(IndexScanDesc scan); extern IndexScanDesc index_beginscan_parallel(Relation heaprel, Relation indexrel, int nkeys, int norderbys, @@ -203,4 +203,4 @@ extern HeapTuple systable_getnext_ordered(SysScanDesc sysscan, ScanDirection direction); extern void systable_endscan_ordered(SysScanDesc sysscan); -#endif /* GENAM_H */ +#endif /* GENAM_H */ diff --git a/src/include/access/generic_xlog.h b/src/include/access/generic_xlog.h index 0dc17f55f2..02696141ea 100644 --- a/src/include/access/generic_xlog.h +++ b/src/include/access/generic_xlog.h @@ -42,4 +42,4 @@ extern const char *generic_identify(uint8 info); extern void generic_desc(StringInfo buf, XLogReaderState *record); extern void generic_mask(char *pagedata, BlockNumber blkno); -#endif /* GENERIC_XLOG_H */ +#endif /* GENERIC_XLOG_H */ diff --git a/src/include/access/gin.h b/src/include/access/gin.h index bd9e8833de..ec83058095 100644 --- a/src/include/access/gin.h +++ b/src/include/access/gin.h @@ -33,7 +33,7 @@ #define GIN_SEARCH_MODE_DEFAULT 0 #define GIN_SEARCH_MODE_INCLUDE_EMPTY 1 #define GIN_SEARCH_MODE_ALL 2 -#define GIN_SEARCH_MODE_EVERYTHING 3 /* for internal use only */ +#define GIN_SEARCH_MODE_EVERYTHING 3 /* for internal use only */ /* * GinStatsData represents stats data for planner use @@ -73,4 +73,4 @@ extern int gin_pending_list_limit; extern void ginGetStats(Relation index, GinStatsData *stats); extern void ginUpdateStats(Relation index, const GinStatsData *stats); -#endif /* GIN_H */ +#endif /* GIN_H */ diff --git a/src/include/access/gin_private.h b/src/include/access/gin_private.h index 986fe6e041..adfdb0c6d9 100644 --- a/src/include/access/gin_private.h +++ b/src/include/access/gin_private.h @@ -75,7 +75,7 @@ typedef struct GinState FmgrInfo extractQueryFn[INDEX_MAX_KEYS]; FmgrInfo consistentFn[INDEX_MAX_KEYS]; FmgrInfo triConsistentFn[INDEX_MAX_KEYS]; - FmgrInfo comparePartialFn[INDEX_MAX_KEYS]; /* optional method */ + FmgrInfo comparePartialFn[INDEX_MAX_KEYS]; /* optional method */ /* canPartialMatch[i] is true if comparePartialFn[i] is valid */ bool canPartialMatch[INDEX_MAX_KEYS]; /* Collations to pass to the support functions */ @@ -95,7 +95,7 @@ extern int ginCompareEntries(GinState *ginstate, OffsetNumber attnum, Datum b, GinNullCategory categoryb); extern int ginCompareAttEntries(GinState *ginstate, OffsetNumber attnuma, Datum a, GinNullCategory categorya, - OffsetNumber attnumb, Datum b, GinNullCategory categoryb); + OffsetNumber attnumb, Datum b, GinNullCategory categoryb); extern Datum *ginExtractEntries(GinState *ginstate, OffsetNumber attnum, Datum value, bool isNull, int32 *nentries, GinNullCategory **categories); @@ -309,7 +309,7 @@ typedef struct GinScanKeyData bool curItemMatches; bool recheckCurItem; bool isFinished; -} GinScanKeyData; +} GinScanKeyData; typedef struct GinScanEntryData { @@ -342,7 +342,7 @@ typedef struct GinScanEntryData bool reduceResult; uint32 predictNumberResult; GinBtreeData btree; -} GinScanEntryData; +} GinScanEntryData; typedef struct GinScanOpaqueData { @@ -473,4 +473,4 @@ ginCompareItemPointers(ItemPointer a, ItemPointer b) extern int ginTraverseLock(Buffer buffer, bool searchMode); -#endif /* GIN_PRIVATE_H */ +#endif /* GIN_PRIVATE_H */ diff --git a/src/include/access/ginblock.h b/src/include/access/ginblock.h index 438912c6a0..114370c7d7 100644 --- a/src/include/access/ginblock.h +++ b/src/include/access/ginblock.h @@ -41,7 +41,7 @@ typedef GinPageOpaqueData *GinPageOpaque; #define GIN_DELETED (1 << 2) #define GIN_META (1 << 3) #define GIN_LIST (1 << 4) -#define GIN_LIST_FULLROW (1 << 5) /* makes sense only on GIN_LIST page */ +#define GIN_LIST_FULLROW (1 << 5) /* makes sense only on GIN_LIST page */ #define GIN_INCOMPLETE_SPLIT (1 << 6) /* page was split, but parent not * updated */ #define GIN_COMPRESSED (1 << 7) @@ -196,10 +196,10 @@ typedef struct */ typedef signed char GinNullCategory; -#define GIN_CAT_NORM_KEY 0 /* normal, non-null key value */ -#define GIN_CAT_NULL_KEY 1 /* null key value */ -#define GIN_CAT_EMPTY_ITEM 2 /* placeholder for zero-key item */ -#define GIN_CAT_NULL_ITEM 3 /* placeholder for null item */ +#define GIN_CAT_NORM_KEY 0 /* normal, non-null key value */ +#define GIN_CAT_NULL_KEY 1 /* null key value */ +#define GIN_CAT_EMPTY_ITEM 2 /* placeholder for zero-key item */ +#define GIN_CAT_NULL_ITEM 3 /* placeholder for null item */ #define GIN_CAT_EMPTY_QUERY (-1) /* placeholder for full-scan query */ /* @@ -333,4 +333,4 @@ typedef struct #define SizeOfGinPostingList(plist) (offsetof(GinPostingList, bytes) + SHORTALIGN((plist)->nbytes) ) #define GinNextPostingListSegment(cur) ((GinPostingList *) (((char *) (cur)) + SizeOfGinPostingList((cur)))) -#endif /* GINBLOCK_H */ +#endif /* GINBLOCK_H */ diff --git a/src/include/access/ginxlog.h b/src/include/access/ginxlog.h index 8decc42cdb..42e0ae90c3 100644 --- a/src/include/access/ginxlog.h +++ b/src/include/access/ginxlog.h @@ -87,14 +87,14 @@ typedef struct * added, followed by the items themselves as ItemPointers. DELETE actions * have no further data. */ -} ginxlogSegmentAction; +} ginxlogSegmentAction; /* Action types */ -#define GIN_SEGMENT_UNMODIFIED 0 /* no action (not used in WAL records) */ -#define GIN_SEGMENT_DELETE 1 /* a whole segment is removed */ -#define GIN_SEGMENT_INSERT 2 /* a whole segment is added */ -#define GIN_SEGMENT_REPLACE 3 /* a segment is replaced */ -#define GIN_SEGMENT_ADDITEMS 4 /* items are added to existing segment */ +#define GIN_SEGMENT_UNMODIFIED 0 /* no action (not used in WAL records) */ +#define GIN_SEGMENT_DELETE 1 /* a whole segment is removed */ +#define GIN_SEGMENT_INSERT 2 /* a whole segment is added */ +#define GIN_SEGMENT_REPLACE 3 /* a segment is replaced */ +#define GIN_SEGMENT_ADDITEMS 4 /* items are added to existing segment */ typedef struct { @@ -214,4 +214,4 @@ extern void gin_xlog_startup(void); extern void gin_xlog_cleanup(void); extern void gin_mask(char *pagedata, BlockNumber blkno); -#endif /* GINXLOG_H */ +#endif /* GINXLOG_H */ diff --git a/src/include/access/gist.h b/src/include/access/gist.h index 5824e90bda..83642189db 100644 --- a/src/include/access/gist.h +++ b/src/include/access/gist.h @@ -105,12 +105,12 @@ typedef struct GIST_SPLITVEC OffsetNumber *spl_left; /* array of entries that go left */ int spl_nleft; /* size of this array */ Datum spl_ldatum; /* Union of keys in spl_left */ - bool spl_ldatum_exists; /* true, if spl_ldatum already exists. */ + bool spl_ldatum_exists; /* true, if spl_ldatum already exists. */ OffsetNumber *spl_right; /* array of entries that go right */ int spl_nright; /* size of the array */ Datum spl_rdatum; /* Union of keys in spl_right */ - bool spl_rdatum_exists; /* true, if spl_rdatum already exists. */ + bool spl_rdatum_exists; /* true, if spl_rdatum already exists. */ } GIST_SPLITVEC; /* @@ -170,4 +170,4 @@ typedef struct do { (e).key = (k); (e).rel = (r); (e).page = (pg); \ (e).offset = (o); (e).leafkey = (l); } while (0) -#endif /* GIST_H */ +#endif /* GIST_H */ diff --git a/src/include/access/gist_private.h b/src/include/access/gist_private.h index 1ad4ed6da7..bfef2df420 100644 --- a/src/include/access/gist_private.h +++ b/src/include/access/gist_private.h @@ -118,7 +118,7 @@ typedef struct GISTSearchHeapItem { ItemPointerData heapPtr; bool recheck; /* T if quals must be rechecked */ - bool recheckDistances; /* T if distances must be rechecked */ + bool recheckDistances; /* T if distances must be rechecked */ HeapTuple recontup; /* data reconstructed from the index, used in * index-only scans */ OffsetNumber offnum; /* track offset in page to mark tuple as @@ -136,8 +136,8 @@ typedef struct GISTSearchItem /* we must store parentlsn to detect whether a split occurred */ GISTSearchHeapItem heap; /* heap info, if heap tuple */ } data; - double distances[FLEXIBLE_ARRAY_MEMBER]; /* numberOfOrderBys - * entries */ + double distances[FLEXIBLE_ARRAY_MEMBER]; /* numberOfOrderBys + * entries */ } GISTSearchItem; #define GISTSearchItemIsHeap(item) ((item).blkno == InvalidBlockNumber) @@ -225,12 +225,12 @@ typedef struct GistSplitVector { GIST_SPLITVEC splitVector; /* passed to/from user PickSplit method */ - Datum spl_lattr[INDEX_MAX_KEYS]; /* Union of subkeys in - * splitVector.spl_left */ + Datum spl_lattr[INDEX_MAX_KEYS]; /* Union of subkeys in + * splitVector.spl_left */ bool spl_lisnull[INDEX_MAX_KEYS]; - Datum spl_rattr[INDEX_MAX_KEYS]; /* Union of subkeys in - * splitVector.spl_right */ + Datum spl_rattr[INDEX_MAX_KEYS]; /* Union of subkeys in + * splitVector.spl_right */ bool spl_risnull[INDEX_MAX_KEYS]; bool *spl_dontcare; /* flags tuples which could go to either side @@ -288,7 +288,7 @@ typedef struct int32 blocksCount; /* current # of blocks occupied by buffer */ BlockNumber pageBlocknum; /* temporary file block # */ - GISTNodeBufferPage *pageBuffer; /* in-memory buffer page */ + GISTNodeBufferPage *pageBuffer; /* in-memory buffer page */ /* is this buffer queued for emptying? */ bool queuedForEmptying; @@ -360,8 +360,8 @@ typedef struct GISTBuildBuffers * loaded in main memory. */ GISTNodeBuffer **loadedBuffers; - int loadedBuffersCount; /* # of entries in loadedBuffers */ - int loadedBuffersLen; /* allocated size of loadedBuffers */ + int loadedBuffersCount; /* # of entries in loadedBuffers */ + int loadedBuffersLen; /* allocated size of loadedBuffers */ /* Level of the current root node (= height of the index tree - 1) */ int rootlevel; @@ -522,4 +522,4 @@ extern void gistRelocateBuildBuffersOnSplit(GISTBuildBuffers *gfbb, List *splitinfo); extern void gistUnloadNodeBuffers(GISTBuildBuffers *gfbb); -#endif /* GIST_PRIVATE_H */ +#endif /* GIST_PRIVATE_H */ diff --git a/src/include/access/gistscan.h b/src/include/access/gistscan.h index 017740d14a..2aea6ad309 100644 --- a/src/include/access/gistscan.h +++ b/src/include/access/gistscan.h @@ -21,4 +21,4 @@ extern void gistrescan(IndexScanDesc scan, ScanKey key, int nkeys, ScanKey orderbys, int norderbys); extern void gistendscan(IndexScanDesc scan); -#endif /* GISTSCAN_H */ +#endif /* GISTSCAN_H */ diff --git a/src/include/access/hash.h b/src/include/access/hash.h index c608b03bb0..4e50a843f7 100644 --- a/src/include/access/hash.h +++ b/src/include/access/hash.h @@ -145,8 +145,7 @@ typedef struct HashScanOpaqueData */ bool hashso_buc_split; /* info about killed items if any (killedItems is NULL if never used) */ - HashScanPosItem *killedItems; /* tids and offset numbers of killed - * items */ + HashScanPosItem *killedItems; /* tids and offset numbers of killed items */ int numKilled; /* number of currently stored items */ } HashScanOpaqueData; @@ -213,13 +212,13 @@ typedef struct HashMetaPageData uint32 hashm_maxbucket; /* ID of maximum bucket in use */ uint32 hashm_highmask; /* mask to modulo into entire table */ uint32 hashm_lowmask; /* mask to modulo into lower half of table */ - uint32 hashm_ovflpoint;/* splitpoint from which ovflpgs being - * allocated */ + uint32 hashm_ovflpoint; /* splitpoint from which ovflpgs being + * allocated */ uint32 hashm_firstfree; /* lowest-number free ovflpage (bit#) */ uint32 hashm_nmaps; /* number of bitmap pages */ RegProcedure hashm_procid; /* hash procedure id from pg_proc */ - uint32 hashm_spares[HASH_MAX_SPLITPOINTS]; /* spare pages before - * each splitpoint */ + uint32 hashm_spares[HASH_MAX_SPLITPOINTS]; /* spare pages before each + * splitpoint */ BlockNumber hashm_mapp[HASH_MAX_BITMAPS]; /* blknos of ovfl bitmaps */ } HashMetaPageData; @@ -242,7 +241,7 @@ typedef HashMetaPageData *HashMetaPage; /* * Constants */ -#define BYTE_TO_BIT 3 /* 2^3 bits/byte */ +#define BYTE_TO_BIT 3 /* 2^3 bits/byte */ #define ALL_SET ((uint32) ~0) /* @@ -339,7 +338,7 @@ extern void _hash_pgaddmultitup(Relation rel, Buffer buf, IndexTuple *itups, extern Buffer _hash_addovflpage(Relation rel, Buffer metabuf, Buffer buf, bool retain_pin); extern BlockNumber _hash_freeovflpage(Relation rel, Buffer bucketbuf, Buffer ovflbuf, Buffer wbuf, IndexTuple *itups, OffsetNumber *itup_offsets, - Size *tups_size, uint16 nitups, BufferAccessStrategy bstrategy); + Size *tups_size, uint16 nitups, BufferAccessStrategy bstrategy); extern void _hash_initbitmapbuffer(Buffer buf, uint16 bmsize, bool initpage); extern void _hash_squeezebucket(Relation rel, Bucket bucket, BlockNumber bucket_blkno, @@ -428,4 +427,4 @@ extern Datum compute_hash(Oid type, Datum value, char locator); extern char *get_compute_hash_function(Oid type, char locator); #endif -#endif /* HASH_H */ +#endif /* HASH_H */ diff --git a/src/include/access/hash_xlog.h b/src/include/access/hash_xlog.h index d4a6a71ca7..c778fdc8df 100644 --- a/src/include/access/hash_xlog.h +++ b/src/include/access/hash_xlog.h @@ -24,14 +24,13 @@ /* * XLOG records for hash operations */ -#define XLOG_HASH_INIT_META_PAGE 0x00 /* initialize the meta page */ -#define XLOG_HASH_INIT_BITMAP_PAGE 0x10 /* initialize the bitmap page */ +#define XLOG_HASH_INIT_META_PAGE 0x00 /* initialize the meta page */ +#define XLOG_HASH_INIT_BITMAP_PAGE 0x10 /* initialize the bitmap page */ #define XLOG_HASH_INSERT 0x20 /* add index tuple without split */ #define XLOG_HASH_ADD_OVFL_PAGE 0x30 /* add overflow page */ #define XLOG_HASH_SPLIT_ALLOCATE_PAGE 0x40 /* allocate new page for split */ #define XLOG_HASH_SPLIT_PAGE 0x50 /* split page */ -#define XLOG_HASH_SPLIT_COMPLETE 0x60 /* completion of split - * operation */ +#define XLOG_HASH_SPLIT_COMPLETE 0x60 /* completion of split operation */ #define XLOG_HASH_MOVE_PAGE_CONTENTS 0x70 /* remove tuples from one page * and add to another page */ #define XLOG_HASH_SQUEEZE_PAGE 0x80 /* add tuples to one of the previous @@ -41,11 +40,10 @@ #define XLOG_HASH_SPLIT_CLEANUP 0xA0 /* clear split-cleanup flag in primary * bucket page after deleting tuples * that are moved due to split */ -#define XLOG_HASH_UPDATE_META_PAGE 0xB0 /* update meta page after - * vacuum */ +#define XLOG_HASH_UPDATE_META_PAGE 0xB0 /* update meta page after vacuum */ -#define XLOG_HASH_VACUUM_ONE_PAGE 0xC0 /* remove dead tuples from - * index page */ +#define XLOG_HASH_VACUUM_ONE_PAGE 0xC0 /* remove dead tuples from index + * page */ /* * xl_hash_split_allocate_page flag values, 8 bits are available. @@ -63,7 +61,7 @@ typedef struct xl_hash_createidx double num_tuples; RegProcedure procid; uint16 ffactor; -} xl_hash_createidx; +} xl_hash_createidx; #define SizeOfHashCreateIdx (offsetof(xl_hash_createidx, ffactor) + sizeof(uint16)) /* @@ -151,9 +149,9 @@ typedef struct xl_hash_split_complete typedef struct xl_hash_move_page_contents { uint16 ntups; - bool is_prim_bucket_same_wrt; /* TRUE if the page to which - * tuples are moved is same as - * primary bucket page */ + bool is_prim_bucket_same_wrt; /* TRUE if the page to which + * tuples are moved is same as + * primary bucket page */ } xl_hash_move_page_contents; #define SizeOfHashMovePageContents \ @@ -176,13 +174,13 @@ typedef struct xl_hash_squeeze_page BlockNumber prevblkno; BlockNumber nextblkno; uint16 ntups; - bool is_prim_bucket_same_wrt; /* TRUE if the page to which - * tuples are moved is same as - * primary bucket page */ - bool is_prev_bucket_same_wrt; /* TRUE if the page to which - * tuples are moved is the - * page previous to the freed - * overflow page */ + bool is_prim_bucket_same_wrt; /* TRUE if the page to which + * tuples are moved is same as + * primary bucket page */ + bool is_prev_bucket_same_wrt; /* TRUE if the page to which + * tuples are moved is the page + * previous to the freed overflow + * page */ } xl_hash_squeeze_page; #define SizeOfHashSqueezePage \ @@ -198,8 +196,8 @@ typedef struct xl_hash_squeeze_page */ typedef struct xl_hash_delete { - bool clear_dead_marking; /* TRUE if this operation clears - * LH_PAGE_HAS_DEAD_TUPLES flag */ + bool clear_dead_marking; /* TRUE if this operation clears + * LH_PAGE_HAS_DEAD_TUPLES flag */ bool is_primary_bucket_page; /* TRUE if the operation is for * primary bucket page */ } xl_hash_delete; @@ -279,4 +277,4 @@ extern void hash_desc(StringInfo buf, XLogReaderState *record); extern const char *hash_identify(uint8 info); extern void hash_mask(char *pagedata, BlockNumber blkno); -#endif /* HASH_XLOG_H */ +#endif /* HASH_XLOG_H */ diff --git a/src/include/access/heapam.h b/src/include/access/heapam.h index 7e85510d2f..b2132e723e 100644 --- a/src/include/access/heapam.h +++ b/src/include/access/heapam.h @@ -117,13 +117,13 @@ extern HeapScanDesc heap_beginscan_bm(Relation relation, Snapshot snapshot, int nkeys, ScanKey key); extern HeapScanDesc heap_beginscan_sampling(Relation relation, Snapshot snapshot, int nkeys, ScanKey key, - bool allow_strat, bool allow_sync, bool allow_pagemode); + bool allow_strat, bool allow_sync, bool allow_pagemode); extern void heap_setscanlimits(HeapScanDesc scan, BlockNumber startBlk, BlockNumber endBlk); extern void heapgetpage(HeapScanDesc scan, BlockNumber page); extern void heap_rescan(HeapScanDesc scan, ScanKey key); extern void heap_rescan_set_params(HeapScanDesc scan, ScanKey key, - bool allow_strat, bool allow_sync, bool allow_pagemode); + bool allow_strat, bool allow_sync, bool allow_pagemode); extern void heap_endscan(HeapScanDesc scan); extern HeapTuple heap_getnext(HeapScanDesc scan, ScanDirection direction); @@ -198,4 +198,4 @@ extern BlockNumber ss_get_location(Relation rel, BlockNumber relnblocks); extern void SyncScanShmemInit(void); extern Size SyncScanShmemSize(void); -#endif /* HEAPAM_H */ +#endif /* HEAPAM_H */ diff --git a/src/include/access/heapam_xlog.h b/src/include/access/heapam_xlog.h index b285f172aa..81a6a395c4 100644 --- a/src/include/access/heapam_xlog.h +++ b/src/include/access/heapam_xlog.h @@ -189,7 +189,7 @@ typedef struct xl_heap_update { TransactionId old_xmax; /* xmax of the old tuple */ OffsetNumber old_offnum; /* old tuple's offset */ - uint8 old_infobits_set; /* infomask bits to set on old tuple */ + uint8 old_infobits_set; /* infomask bits to set on old tuple */ uint8 flags; TransactionId new_xmax; /* xmax of the new tuple */ OffsetNumber new_offnum; /* new tuple's offset */ @@ -399,4 +399,4 @@ extern void heap_execute_freeze_tuple(HeapTupleHeader tuple, extern XLogRecPtr log_heap_visible(RelFileNode rnode, Buffer heap_buffer, Buffer vm_buffer, TransactionId cutoff_xid, uint8 flags); -#endif /* HEAPAM_XLOG_H */ +#endif /* HEAPAM_XLOG_H */ diff --git a/src/include/access/hio.h b/src/include/access/hio.h index 2824f23218..4a8beb63a6 100644 --- a/src/include/access/hio.h +++ b/src/include/access/hio.h @@ -30,9 +30,9 @@ */ typedef struct BulkInsertStateData { - BufferAccessStrategy strategy; /* our BULKWRITE strategy object */ + BufferAccessStrategy strategy; /* our BULKWRITE strategy object */ Buffer current_buf; /* current insertion target page */ -} BulkInsertStateData; +} BulkInsertStateData; extern void RelationPutHeapTuple(Relation relation, Buffer buffer, @@ -42,4 +42,4 @@ extern Buffer RelationGetBufferForTuple(Relation relation, Size len, BulkInsertState bistate, Buffer *vmbuffer, Buffer *vmbuffer_other); -#endif /* HIO_H */ +#endif /* HIO_H */ diff --git a/src/include/access/htup.h b/src/include/access/htup.h index 1d31b5f1c2..187f18c735 100644 --- a/src/include/access/htup.h +++ b/src/include/access/htup.h @@ -105,4 +105,4 @@ extern void HeapTupleHeaderAdjustCmax(HeapTupleHeader tup, /* Prototype for HeapTupleHeader accessors in heapam.c */ extern TransactionId HeapTupleGetUpdateXid(HeapTupleHeader tuple); -#endif /* HTUP_H */ +#endif /* HTUP_H */ diff --git a/src/include/access/htup_details.h b/src/include/access/htup_details.h index e365f4f2b4..3e1676c7e6 100644 --- a/src/include/access/htup_details.h +++ b/src/include/access/htup_details.h @@ -748,7 +748,7 @@ struct MinimalTupleData extern Datum fastgetattr(HeapTuple tup, int attnum, TupleDesc tupleDesc, bool *isnull); -#endif /* defined(DISABLE_COMPLEX_MACRO) */ +#endif /* defined(DISABLE_COMPLEX_MACRO) */ /* ---------------- @@ -821,4 +821,4 @@ extern MinimalTuple heap_copy_minimal_tuple(MinimalTuple mtup); extern HeapTuple heap_tuple_from_minimal_tuple(MinimalTuple mtup); extern MinimalTuple minimal_tuple_from_heap_tuple(HeapTuple htup); -#endif /* HTUP_DETAILS_H */ +#endif /* HTUP_DETAILS_H */ diff --git a/src/include/access/itup.h b/src/include/access/itup.h index e9ec8e27e2..a94e7948b4 100644 --- a/src/include/access/itup.h +++ b/src/include/access/itup.h @@ -55,9 +55,9 @@ typedef IndexTupleData *IndexTuple; typedef struct IndexAttributeBitMapData { bits8 bits[(INDEX_MAX_KEYS + 8 - 1) / 8]; -} IndexAttributeBitMapData; +} IndexAttributeBitMapData; -typedef IndexAttributeBitMapData *IndexAttributeBitMap; +typedef IndexAttributeBitMapData * IndexAttributeBitMap; /* * t_info manipulation macros @@ -148,4 +148,4 @@ extern void index_deform_tuple(IndexTuple tup, TupleDesc tupleDescriptor, Datum *values, bool *isnull); extern IndexTuple CopyIndexTuple(IndexTuple source); -#endif /* ITUP_H */ +#endif /* ITUP_H */ diff --git a/src/include/access/multixact.h b/src/include/access/multixact.h index 85997a41fa..d5e18c6733 100644 --- a/src/include/access/multixact.h +++ b/src/include/access/multixact.h @@ -157,4 +157,4 @@ extern const char *multixact_identify(uint8 info); extern char *mxid_to_string(MultiXactId multi, int nmembers, MultiXactMember *members); -#endif /* MULTIXACT_H */ +#endif /* MULTIXACT_H */ diff --git a/src/include/access/nbtree.h b/src/include/access/nbtree.h index 15771ce9e0..e6abbec280 100644 --- a/src/include/access/nbtree.h +++ b/src/include/access/nbtree.h @@ -421,9 +421,9 @@ typedef BTScanOpaqueData *BTScanOpaque; * to use bits 16-31 (see skey.h). The uppermost bits are copied from the * index's indoption[] array entry for the index attribute. */ -#define SK_BT_REQFWD 0x00010000 /* required to continue forward scan */ -#define SK_BT_REQBKWD 0x00020000 /* required to continue backward scan */ -#define SK_BT_INDOPTION_SHIFT 24 /* must clear the above bits */ +#define SK_BT_REQFWD 0x00010000 /* required to continue forward scan */ +#define SK_BT_REQBKWD 0x00020000 /* required to continue backward scan */ +#define SK_BT_INDOPTION_SHIFT 24 /* must clear the above bits */ #define SK_BT_DESC (INDOPTION_DESC << SK_BT_INDOPTION_SHIFT) #define SK_BT_NULLS_FIRST (INDOPTION_NULLS_FIRST << SK_BT_INDOPTION_SHIFT) @@ -556,4 +556,4 @@ extern void _bt_spool(BTSpool *btspool, ItemPointer self, Datum *values, bool *isnull); extern void _bt_leafbuild(BTSpool *btspool, BTSpool *spool2); -#endif /* NBTREE_H */ +#endif /* NBTREE_H */ diff --git a/src/include/access/nbtxlog.h b/src/include/access/nbtxlog.h index d6a3085923..a46e9c36f3 100644 --- a/src/include/access/nbtxlog.h +++ b/src/include/access/nbtxlog.h @@ -32,9 +32,9 @@ #define XLOG_BTREE_SPLIT_R_ROOT 0x60 /* as above, new item on right */ #define XLOG_BTREE_DELETE 0x70 /* delete leaf index tuples for a page */ #define XLOG_BTREE_UNLINK_PAGE 0x80 /* delete a half-dead page */ -#define XLOG_BTREE_UNLINK_PAGE_META 0x90 /* same, and update metapage */ +#define XLOG_BTREE_UNLINK_PAGE_META 0x90 /* same, and update metapage */ #define XLOG_BTREE_NEWROOT 0xA0 /* new root page */ -#define XLOG_BTREE_MARK_PAGE_HALFDEAD 0xB0 /* mark a leaf as half-dead */ +#define XLOG_BTREE_MARK_PAGE_HALFDEAD 0xB0 /* mark a leaf as half-dead */ #define XLOG_BTREE_VACUUM 0xC0 /* delete entries on a page during * vacuum */ #define XLOG_BTREE_REUSE_PAGE 0xD0 /* old page is about to be reused from @@ -252,4 +252,4 @@ extern void btree_desc(StringInfo buf, XLogReaderState *record); extern const char *btree_identify(uint8 info); extern void btree_mask(char *pagedata, BlockNumber blkno); -#endif /* NBXLOG_H */ +#endif /* NBXLOG_H */ diff --git a/src/include/access/parallel.h b/src/include/access/parallel.h index 590e27a484..e3e0cecf1e 100644 --- a/src/include/access/parallel.h +++ b/src/include/access/parallel.h @@ -67,4 +67,4 @@ extern void ParallelWorkerReportLastRecEnd(XLogRecPtr last_xlog_end); extern void ParallelWorkerMain(Datum main_arg); -#endif /* PARALLEL_H */ +#endif /* PARALLEL_H */ diff --git a/src/include/access/printsimple.h b/src/include/access/printsimple.h index 3f3e7a3840..edf28cece9 100644 --- a/src/include/access/printsimple.h +++ b/src/include/access/printsimple.h @@ -20,4 +20,4 @@ extern bool printsimple(TupleTableSlot *slot, DestReceiver *self); extern void printsimple_startup(DestReceiver *self, int operation, TupleDesc tupdesc); -#endif /* PRINTSIMPLE_H */ +#endif /* PRINTSIMPLE_H */ diff --git a/src/include/access/printtup.h b/src/include/access/printtup.h index a828889c4f..641715e416 100644 --- a/src/include/access/printtup.h +++ b/src/include/access/printtup.h @@ -32,4 +32,4 @@ extern void spi_dest_startup(DestReceiver *self, int operation, TupleDesc typeinfo); extern bool spi_printtup(TupleTableSlot *slot, DestReceiver *self); -#endif /* PRINTTUP_H */ +#endif /* PRINTTUP_H */ diff --git a/src/include/access/reloptions.h b/src/include/access/reloptions.h index 91b2cd7bb2..5cdaa3bff1 100644 --- a/src/include/access/reloptions.h +++ b/src/include/access/reloptions.h @@ -280,4 +280,4 @@ extern bytea *attribute_reloptions(Datum reloptions, bool validate); extern bytea *tablespace_reloptions(Datum reloptions, bool validate); extern LOCKMODE AlterTableGetRelOptionsLockLevel(List *defList); -#endif /* RELOPTIONS_H */ +#endif /* RELOPTIONS_H */ diff --git a/src/include/access/relscan.h b/src/include/access/relscan.h index f4d4f1ee71..a20646b2b7 100644 --- a/src/include/access/relscan.h +++ b/src/include/access/relscan.h @@ -39,7 +39,7 @@ typedef struct ParallelHeapScanDescData BlockNumber phs_startblock; /* starting block number */ BlockNumber phs_cblock; /* current block number */ char phs_snapshot_data[FLEXIBLE_ARRAY_MEMBER]; -} ParallelHeapScanDescData; +} ParallelHeapScanDescData; typedef struct HeapScanDescData { @@ -75,7 +75,7 @@ typedef struct HeapScanDescData int rs_cindex; /* current tuple's index in vistuples */ int rs_ntuples; /* number of visible tuples on page */ OffsetNumber rs_vistuples[MaxHeapTuplesPerPage]; /* their offsets */ -} HeapScanDescData; +} HeapScanDescData; /* * We use the same IndexScanDescData structure for both amgettuple-based @@ -89,14 +89,14 @@ typedef struct IndexScanDescData Relation indexRelation; /* index relation descriptor */ Snapshot xs_snapshot; /* snapshot to see */ int numberOfKeys; /* number of index qualifier conditions */ - int numberOfOrderBys; /* number of ordering operators */ + int numberOfOrderBys; /* number of ordering operators */ ScanKey keyData; /* array of index qualifier descriptors */ ScanKey orderByData; /* array of ordering op descriptors */ bool xs_want_itup; /* caller requests index tuples */ bool xs_temp_snap; /* unregister snapshot at scan end? */ /* signaling to index AM about killing index tuples */ - bool kill_prior_tuple; /* last-returned tuple is dead */ + bool kill_prior_tuple; /* last-returned tuple is dead */ bool ignore_killed_tuples; /* do not return killed entries */ bool xactStartedInRecovery; /* prevents killing/seeing killed * tuples */ @@ -137,7 +137,7 @@ typedef struct IndexScanDescData /* parallel index scan information, in shared memory */ ParallelIndexScanDesc parallel_scan; -} IndexScanDescData; +} IndexScanDescData; /* Generic structure for parallel scans */ typedef struct ParallelIndexScanDescData @@ -146,7 +146,7 @@ typedef struct ParallelIndexScanDescData Oid ps_indexid; Size ps_offset; /* Offset in bytes of am specific structure */ char ps_snapshot_data[FLEXIBLE_ARRAY_MEMBER]; -} ParallelIndexScanDescData; +} ParallelIndexScanDescData; /* Struct for heap-or-index scans of system tables */ typedef struct SysScanDescData @@ -156,6 +156,6 @@ typedef struct SysScanDescData HeapScanDesc scan; /* only valid in heap-scan case */ IndexScanDesc iscan; /* only valid in index-scan case */ Snapshot snapshot; /* snapshot to unregister at end of scan */ -} SysScanDescData; +} SysScanDescData; -#endif /* RELSCAN_H */ +#endif /* RELSCAN_H */ diff --git a/src/include/access/rewriteheap.h b/src/include/access/rewriteheap.h index 564c2ad0f5..91ff36707a 100644 --- a/src/include/access/rewriteheap.h +++ b/src/include/access/rewriteheap.h @@ -54,4 +54,4 @@ typedef struct LogicalRewriteMappingData #define LOGICAL_REWRITE_FORMAT "map-%x-%x-%X_%X-%x-%x" void CheckPointLogicalRewriteHeap(void); -#endif /* REWRITE_HEAP_H */ +#endif /* REWRITE_HEAP_H */ diff --git a/src/include/access/rmgr.h b/src/include/access/rmgr.h index 64b92ff33a..c9b5c56a4c 100644 --- a/src/include/access/rmgr.h +++ b/src/include/access/rmgr.h @@ -32,4 +32,4 @@ typedef enum RmgrIds #define RM_MAX_ID (RM_NEXT_ID - 1) -#endif /* RMGR_H */ +#endif /* RMGR_H */ diff --git a/src/include/access/sdir.h b/src/include/access/sdir.h index 347e910a41..65eab48551 100644 --- a/src/include/access/sdir.h +++ b/src/include/access/sdir.h @@ -55,4 +55,4 @@ typedef enum ScanDirection #define ScanDirectionIsForward(direction) \ ((bool) ((direction) == ForwardScanDirection)) -#endif /* SDIR_H */ +#endif /* SDIR_H */ diff --git a/src/include/access/skey.h b/src/include/access/skey.h index 01cc940363..2f4814f140 100644 --- a/src/include/access/skey.h +++ b/src/include/access/skey.h @@ -112,16 +112,15 @@ typedef ScanKeyData *ScanKey; * bits should be defined here). Bits 16-31 are reserved for use within * individual index access methods. */ -#define SK_ISNULL 0x0001 /* sk_argument is NULL */ -#define SK_UNARY 0x0002 /* unary operator (not supported!) */ -#define SK_ROW_HEADER 0x0004 /* row comparison header (see above) */ -#define SK_ROW_MEMBER 0x0008 /* row comparison member (see above) */ -#define SK_ROW_END 0x0010 /* last row comparison member */ -#define SK_SEARCHARRAY 0x0020 /* scankey represents ScalarArrayOp */ -#define SK_SEARCHNULL 0x0040 /* scankey represents "col IS NULL" */ -#define SK_SEARCHNOTNULL 0x0080 /* scankey represents "col IS NOT - * NULL" */ -#define SK_ORDER_BY 0x0100 /* scankey is for ORDER BY op */ +#define SK_ISNULL 0x0001 /* sk_argument is NULL */ +#define SK_UNARY 0x0002 /* unary operator (not supported!) */ +#define SK_ROW_HEADER 0x0004 /* row comparison header (see above) */ +#define SK_ROW_MEMBER 0x0008 /* row comparison member (see above) */ +#define SK_ROW_END 0x0010 /* last row comparison member */ +#define SK_SEARCHARRAY 0x0020 /* scankey represents ScalarArrayOp */ +#define SK_SEARCHNULL 0x0040 /* scankey represents "col IS NULL" */ +#define SK_SEARCHNOTNULL 0x0080 /* scankey represents "col IS NOT NULL" */ +#define SK_ORDER_BY 0x0100 /* scankey is for ORDER BY op */ /* @@ -149,4 +148,4 @@ extern void ScanKeyEntryInitializeWithInfo(ScanKey entry, FmgrInfo *finfo, Datum argument); -#endif /* SKEY_H */ +#endif /* SKEY_H */ diff --git a/src/include/access/slru.h b/src/include/access/slru.h index 722867d5d2..f1b4d6cc9d 100644 --- a/src/include/access/slru.h +++ b/src/include/access/slru.h @@ -155,7 +155,7 @@ extern void SimpleLruTruncate(SlruCtl ctl, int cutoffPage); extern bool SimpleLruDoesPhysicalPageExist(SlruCtl ctl, int pageno); typedef bool (*SlruScanCallback) (SlruCtl ctl, char *filename, int segpage, - void *data); + void *data); extern bool SlruScanDirectory(SlruCtl ctl, SlruScanCallback callback, void *data); extern void SlruDeleteSegment(SlruCtl ctl, int segno); @@ -165,4 +165,4 @@ extern bool SlruScanDirCbReportPresence(SlruCtl ctl, char *filename, extern bool SlruScanDirCbDeleteAll(SlruCtl ctl, char *filename, int segpage, void *data); -#endif /* SLRU_H */ +#endif /* SLRU_H */ diff --git a/src/include/access/spgist.h b/src/include/access/spgist.h index 9dca8fde7d..d1bc396e6d 100644 --- a/src/include/access/spgist.h +++ b/src/include/access/spgist.h @@ -74,33 +74,33 @@ typedef enum spgChooseResultType typedef struct spgChooseOut { - spgChooseResultType resultType; /* action code, see above */ + spgChooseResultType resultType; /* action code, see above */ union { struct /* results for spgMatchNode */ { int nodeN; /* descend to this node (index from 0) */ - int levelAdd; /* increment level by this much */ - Datum restDatum; /* new leaf datum */ + int levelAdd; /* increment level by this much */ + Datum restDatum; /* new leaf datum */ } matchNode; struct /* results for spgAddNode */ { - Datum nodeLabel; /* new node's label */ + Datum nodeLabel; /* new node's label */ int nodeN; /* where to insert it (index from 0) */ } addNode; struct /* results for spgSplitTuple */ { /* Info to form new upper-level inner tuple with one child tuple */ - bool prefixHasPrefix; /* tuple should have a prefix? */ - Datum prefixPrefixDatum; /* if so, its value */ + bool prefixHasPrefix; /* tuple should have a prefix? */ + Datum prefixPrefixDatum; /* if so, its value */ int prefixNNodes; /* number of nodes */ - Datum *prefixNodeLabels; /* their labels (or NULL for - * no labels) */ - int childNodeN; /* which node gets child tuple */ + Datum *prefixNodeLabels; /* their labels (or NULL for no + * labels) */ + int childNodeN; /* which node gets child tuple */ /* Info to form new lower-level inner tuple with all old nodes */ - bool postfixHasPrefix; /* tuple should have a prefix? */ - Datum postfixPrefixDatum; /* if so, its value */ + bool postfixHasPrefix; /* tuple should have a prefix? */ + Datum postfixPrefixDatum; /* if so, its value */ } splitTuple; } result; } spgChooseOut; @@ -123,7 +123,7 @@ typedef struct spgPickSplitOut int nNodes; /* number of nodes for new inner tuple */ Datum *nodeLabels; /* their labels (or NULL for no labels) */ - int *mapTuplesToNodes; /* node index for each leaf tuple */ + int *mapTuplesToNodes; /* node index for each leaf tuple */ Datum *leafTupleDatums; /* datum to store in each new leaf tuple */ } spgPickSplitOut; @@ -135,10 +135,9 @@ typedef struct spgInnerConsistentIn ScanKey scankeys; /* array of operators and comparison values */ int nkeys; /* length of array */ - Datum reconstructedValue; /* value reconstructed at parent */ + Datum reconstructedValue; /* value reconstructed at parent */ void *traversalValue; /* opclass-specific traverse value */ - MemoryContext traversalMemoryContext; /* put new traverse values - * here */ + MemoryContext traversalMemoryContext; /* put new traverse values here */ int level; /* current level (counting from zero) */ bool returnData; /* original data must be returned? */ @@ -167,7 +166,7 @@ typedef struct spgLeafConsistentIn ScanKey scankeys; /* array of operators and comparison values */ int nkeys; /* length of array */ - Datum reconstructedValue; /* value reconstructed at parent */ + Datum reconstructedValue; /* value reconstructed at parent */ void *traversalValue; /* opclass-specific traverse value */ int level; /* current level (counting from zero) */ bool returnData; /* original data must be returned? */ @@ -214,4 +213,4 @@ extern IndexBulkDeleteResult *spgvacuumcleanup(IndexVacuumInfo *info, /* spgvalidate.c */ extern bool spgvalidate(Oid opclassoid); -#endif /* SPGIST_H */ +#endif /* SPGIST_H */ diff --git a/src/include/access/spgist_private.h b/src/include/access/spgist_private.h index 4072c050de..1c4b321b6c 100644 --- a/src/include/access/spgist_private.h +++ b/src/include/access/spgist_private.h @@ -48,8 +48,8 @@ typedef SpGistPageOpaqueData *SpGistPageOpaque; /* Flag bits in page special space */ #define SPGIST_META (1<<0) -#define SPGIST_DELETED (1<<1) /* never set, but keep for backwards - * compatibility */ +#define SPGIST_DELETED (1<<1) /* never set, but keep for backwards + * compatibility */ #define SPGIST_LEAF (1<<2) #define SPGIST_NULLS (1<<3) @@ -94,7 +94,7 @@ typedef struct SpGistLUPCache typedef struct SpGistMetaPageData { uint32 magicNumber; /* for identity cross-check */ - SpGistLUPCache lastUsedPages; /* shared storage of last-used info */ + SpGistLUPCache lastUsedPages; /* shared storage of last-used info */ } SpGistMetaPageData; #define SPGIST_MAGIC_NUMBER (0xBA0BABEE) @@ -120,10 +120,10 @@ typedef struct SpGistState spgConfigOut config; /* filled in by opclass config method */ SpGistTypeDesc attType; /* type of input data and leaf values */ - SpGistTypeDesc attPrefixType; /* type of inner-tuple prefix values */ + SpGistTypeDesc attPrefixType; /* type of inner-tuple prefix values */ SpGistTypeDesc attLabelType; /* type of node label values */ - char *deadTupleStorage; /* workspace for spgFormDeadTuple */ + char *deadTupleStorage; /* workspace for spgFormDeadTuple */ TransactionId myXid; /* XID to use when creating a redirect tuple */ bool isBuild; /* true if doing index build */ @@ -159,7 +159,7 @@ typedef struct SpGistScanOpaqueData int iPtr; /* index for scanning through same */ ItemPointerData heapPtrs[MaxIndexTuplesPerPage]; /* TIDs from cur page */ bool recheck[MaxIndexTuplesPerPage]; /* their recheck flags */ - HeapTuple reconTups[MaxIndexTuplesPerPage]; /* reconstructed tuples */ + HeapTuple reconTups[MaxIndexTuplesPerPage]; /* reconstructed tuples */ /* * Note: using MaxIndexTuplesPerPage above is a bit hokey since @@ -179,10 +179,10 @@ typedef struct SpGistCache spgConfigOut config; /* filled in by opclass config method */ SpGistTypeDesc attType; /* type of input data and leaf values */ - SpGistTypeDesc attPrefixType; /* type of inner-tuple prefix values */ + SpGistTypeDesc attPrefixType; /* type of inner-tuple prefix values */ SpGistTypeDesc attLabelType; /* type of node label values */ - SpGistLUPCache lastUsedPages; /* local storage of last-used info */ + SpGistLUPCache lastUsedPages; /* local storage of last-used info */ } SpGistCache; @@ -418,4 +418,4 @@ extern void spgPageIndexMultiDelete(SpGistState *state, Page page, extern bool spgdoinsert(Relation index, SpGistState *state, ItemPointer heapPtr, Datum datum, bool isnull); -#endif /* SPGIST_PRIVATE_H */ +#endif /* SPGIST_PRIVATE_H */ diff --git a/src/include/access/spgxlog.h b/src/include/access/spgxlog.h index ff597f75db..cf4331be4a 100644 --- a/src/include/access/spgxlog.h +++ b/src/include/access/spgxlog.h @@ -238,7 +238,7 @@ typedef struct spgxlogVacuumRoot typedef struct spgxlogVacuumRedirect { uint16 nToPlaceholder; /* number of redirects to make placeholders */ - OffsetNumber firstPlaceholder; /* first placeholder tuple to remove */ + OffsetNumber firstPlaceholder; /* first placeholder tuple to remove */ TransactionId newestRedirectXid; /* newest XID of removed redirects */ /* offsets of redirect tuples to make placeholders follow */ @@ -254,4 +254,4 @@ extern void spg_xlog_startup(void); extern void spg_xlog_cleanup(void); extern void spg_mask(char *pagedata, BlockNumber blkno); -#endif /* SPGXLOG_H */ +#endif /* SPGXLOG_H */ diff --git a/src/include/access/stratnum.h b/src/include/access/stratnum.h index 489e5c595e..91d57605b2 100644 --- a/src/include/access/stratnum.h +++ b/src/include/access/stratnum.h @@ -41,35 +41,35 @@ typedef uint16 StrategyNumber; * The first few of these come from the R-Tree indexing method (hence the * names); the others have been added over time as they have been needed. */ -#define RTLeftStrategyNumber 1 /* for << */ -#define RTOverLeftStrategyNumber 2 /* for &< */ -#define RTOverlapStrategyNumber 3 /* for && */ -#define RTOverRightStrategyNumber 4 /* for &> */ -#define RTRightStrategyNumber 5 /* for >> */ -#define RTSameStrategyNumber 6 /* for ~= */ -#define RTContainsStrategyNumber 7 /* for @> */ -#define RTContainedByStrategyNumber 8 /* for <@ */ -#define RTOverBelowStrategyNumber 9 /* for &<| */ -#define RTBelowStrategyNumber 10 /* for <<| */ -#define RTAboveStrategyNumber 11 /* for |>> */ -#define RTOverAboveStrategyNumber 12 /* for |&> */ -#define RTOldContainsStrategyNumber 13 /* for old spelling of @> */ -#define RTOldContainedByStrategyNumber 14 /* for old spelling of <@ */ -#define RTKNNSearchStrategyNumber 15 /* for <-> (distance) */ -#define RTContainsElemStrategyNumber 16 /* for range types @> elem */ -#define RTAdjacentStrategyNumber 17 /* for -|- */ -#define RTEqualStrategyNumber 18 /* for = */ -#define RTNotEqualStrategyNumber 19 /* for != */ -#define RTLessStrategyNumber 20 /* for < */ -#define RTLessEqualStrategyNumber 21 /* for <= */ -#define RTGreaterStrategyNumber 22 /* for > */ -#define RTGreaterEqualStrategyNumber 23 /* for >= */ -#define RTSubStrategyNumber 24 /* for inet >> */ -#define RTSubEqualStrategyNumber 25 /* for inet <<= */ -#define RTSuperStrategyNumber 26 /* for inet << */ -#define RTSuperEqualStrategyNumber 27 /* for inet >>= */ +#define RTLeftStrategyNumber 1 /* for << */ +#define RTOverLeftStrategyNumber 2 /* for &< */ +#define RTOverlapStrategyNumber 3 /* for && */ +#define RTOverRightStrategyNumber 4 /* for &> */ +#define RTRightStrategyNumber 5 /* for >> */ +#define RTSameStrategyNumber 6 /* for ~= */ +#define RTContainsStrategyNumber 7 /* for @> */ +#define RTContainedByStrategyNumber 8 /* for <@ */ +#define RTOverBelowStrategyNumber 9 /* for &<| */ +#define RTBelowStrategyNumber 10 /* for <<| */ +#define RTAboveStrategyNumber 11 /* for |>> */ +#define RTOverAboveStrategyNumber 12 /* for |&> */ +#define RTOldContainsStrategyNumber 13 /* for old spelling of @> */ +#define RTOldContainedByStrategyNumber 14 /* for old spelling of <@ */ +#define RTKNNSearchStrategyNumber 15 /* for <-> (distance) */ +#define RTContainsElemStrategyNumber 16 /* for range types @> elem */ +#define RTAdjacentStrategyNumber 17 /* for -|- */ +#define RTEqualStrategyNumber 18 /* for = */ +#define RTNotEqualStrategyNumber 19 /* for != */ +#define RTLessStrategyNumber 20 /* for < */ +#define RTLessEqualStrategyNumber 21 /* for <= */ +#define RTGreaterStrategyNumber 22 /* for > */ +#define RTGreaterEqualStrategyNumber 23 /* for >= */ +#define RTSubStrategyNumber 24 /* for inet >> */ +#define RTSubEqualStrategyNumber 25 /* for inet <<= */ +#define RTSuperStrategyNumber 26 /* for inet << */ +#define RTSuperEqualStrategyNumber 27 /* for inet >>= */ #define RTMaxStrategyNumber 27 -#endif /* STRATNUM_H */ +#endif /* STRATNUM_H */ diff --git a/src/include/access/subtrans.h b/src/include/access/subtrans.h index 847359873a..41716d7b71 100644 --- a/src/include/access/subtrans.h +++ b/src/include/access/subtrans.h @@ -27,4 +27,4 @@ extern void CheckPointSUBTRANS(void); extern void ExtendSUBTRANS(TransactionId newestXact); extern void TruncateSUBTRANS(TransactionId oldestXact); -#endif /* SUBTRANS_H */ +#endif /* SUBTRANS_H */ diff --git a/src/include/access/sysattr.h b/src/include/access/sysattr.h index 348c67ed86..1b3ab8e4aa 100644 --- a/src/include/access/sysattr.h +++ b/src/include/access/sysattr.h @@ -33,4 +33,4 @@ #endif -#endif /* SYSATTR_H */ +#endif /* SYSATTR_H */ diff --git a/src/include/access/timeline.h b/src/include/access/timeline.h index c1911feb16..4bdb0c1f4f 100644 --- a/src/include/access/timeline.h +++ b/src/include/access/timeline.h @@ -41,4 +41,4 @@ extern TimeLineID tliOfPointInHistory(XLogRecPtr ptr, List *history); extern XLogRecPtr tliSwitchPoint(TimeLineID tli, List *history, TimeLineID *nextTLI); -#endif /* TIMELINE_H */ +#endif /* TIMELINE_H */ diff --git a/src/include/access/transam.h b/src/include/access/transam.h index e357d5dea8..9296bcc7f1 100644 --- a/src/include/access/transam.h +++ b/src/include/access/transam.h @@ -199,4 +199,4 @@ extern void AdvanceOldestClogXid(TransactionId oldest_datfrozenxid); extern bool ForceTransactionIdLimitUpdate(void); extern Oid GetNewObjectId(void); -#endif /* TRAMSAM_H */ +#endif /* TRAMSAM_H */ diff --git a/src/include/access/tsmapi.h b/src/include/access/tsmapi.h index d07b3f25a9..3d94cc6466 100644 --- a/src/include/access/tsmapi.h +++ b/src/include/access/tsmapi.h @@ -21,24 +21,24 @@ */ typedef void (*SampleScanGetSampleSize_function) (PlannerInfo *root, - RelOptInfo *baserel, - List *paramexprs, - BlockNumber *pages, - double *tuples); + RelOptInfo *baserel, + List *paramexprs, + BlockNumber *pages, + double *tuples); typedef void (*InitSampleScan_function) (SampleScanState *node, - int eflags); + int eflags); typedef void (*BeginSampleScan_function) (SampleScanState *node, - Datum *params, - int nparams, - uint32 seed); + Datum *params, + int nparams, + uint32 seed); typedef BlockNumber (*NextSampleBlock_function) (SampleScanState *node); typedef OffsetNumber (*NextSampleTuple_function) (SampleScanState *node, - BlockNumber blockno, - OffsetNumber maxoffset); + BlockNumber blockno, + OffsetNumber maxoffset); typedef void (*EndSampleScan_function) (SampleScanState *node); @@ -67,15 +67,15 @@ typedef struct TsmRoutine SampleScanGetSampleSize_function SampleScanGetSampleSize; /* Functions for executing a SampleScan on a physical table */ - InitSampleScan_function InitSampleScan; /* can be NULL */ + InitSampleScan_function InitSampleScan; /* can be NULL */ BeginSampleScan_function BeginSampleScan; NextSampleBlock_function NextSampleBlock; /* can be NULL */ NextSampleTuple_function NextSampleTuple; - EndSampleScan_function EndSampleScan; /* can be NULL */ + EndSampleScan_function EndSampleScan; /* can be NULL */ } TsmRoutine; /* Functions in access/tablesample/tablesample.c */ extern TsmRoutine *GetTsmRoutine(Oid tsmhandler); -#endif /* TSMAPI_H */ +#endif /* TSMAPI_H */ diff --git a/src/include/access/tupconvert.h b/src/include/access/tupconvert.h index e86cfd56c8..173904adae 100644 --- a/src/include/access/tupconvert.h +++ b/src/include/access/tupconvert.h @@ -46,4 +46,4 @@ extern HeapTuple do_convert_tuple(HeapTuple tuple, TupleConversionMap *map); extern void free_conversion_map(TupleConversionMap *map); -#endif /* TUPCONVERT_H */ +#endif /* TUPCONVERT_H */ diff --git a/src/include/access/tupdesc.h b/src/include/access/tupdesc.h index b48f839028..e7065d70ba 100644 --- a/src/include/access/tupdesc.h +++ b/src/include/access/tupdesc.h @@ -78,7 +78,7 @@ typedef struct tupleDesc int32 tdtypmod; /* typmod for tuple type */ bool tdhasoid; /* tuple has oid attribute in its header */ int tdrefcount; /* reference count, or -1 if not counting */ -} *TupleDesc; +} *TupleDesc; extern TupleDesc CreateTemplateTupleDesc(int natts, bool hasoid); @@ -134,4 +134,4 @@ extern TupleDesc BuildDescForRelation(List *schema); extern TupleDesc BuildDescFromLists(List *names, List *types, List *typmods, List *collations); -#endif /* TUPDESC_H */ +#endif /* TUPDESC_H */ diff --git a/src/include/access/tupmacs.h b/src/include/access/tupmacs.h index b5369108cc..6746203828 100644 --- a/src/include/access/tupmacs.h +++ b/src/include/access/tupmacs.h @@ -88,7 +88,7 @@ : \ PointerGetDatum((char *) (T)) \ ) -#endif /* SIZEOF_DATUM == 8 */ +#endif /* SIZEOF_DATUM == 8 */ /* * att_align_datum aligns the given offset as needed for a datum of alignment @@ -238,6 +238,6 @@ break; \ } \ } while (0) -#endif /* SIZEOF_DATUM == 8 */ +#endif /* SIZEOF_DATUM == 8 */ #endif diff --git a/src/include/access/tuptoaster.h b/src/include/access/tuptoaster.h index c7abeed812..fd9f83ac44 100644 --- a/src/include/access/tuptoaster.h +++ b/src/include/access/tuptoaster.h @@ -84,7 +84,7 @@ * * NB: Changing TOAST_MAX_CHUNK_SIZE requires an initdb. */ -#define EXTERN_TUPLES_PER_PAGE 4 /* tweak only this */ +#define EXTERN_TUPLES_PER_PAGE 4 /* tweak only this */ #define EXTERN_TUPLE_MAX_SIZE MaximumBytesPerTuple(EXTERN_TUPLES_PER_PAGE) @@ -152,7 +152,7 @@ extern void toast_delete(Relation rel, HeapTuple oldtup, bool is_speculative); * in compressed format. * ---------- */ -extern struct varlena *heap_tuple_fetch_attr(struct varlena * attr); +extern struct varlena *heap_tuple_fetch_attr(struct varlena *attr); /* ---------- * heap_tuple_untoast_attr() - @@ -161,7 +161,7 @@ extern struct varlena *heap_tuple_fetch_attr(struct varlena * attr); * it as needed. * ---------- */ -extern struct varlena *heap_tuple_untoast_attr(struct varlena * attr); +extern struct varlena *heap_tuple_untoast_attr(struct varlena *attr); /* ---------- * heap_tuple_untoast_attr_slice() - @@ -170,7 +170,7 @@ extern struct varlena *heap_tuple_untoast_attr(struct varlena * attr); * (Handles all cases for attribute storage) * ---------- */ -extern struct varlena *heap_tuple_untoast_attr_slice(struct varlena * attr, +extern struct varlena *heap_tuple_untoast_attr_slice(struct varlena *attr, int32 sliceoffset, int32 slicelength); @@ -236,4 +236,4 @@ extern Size toast_datum_size(Datum value); */ extern Oid toast_get_valid_index(Oid toastoid, LOCKMODE lock); -#endif /* TUPTOASTER_H */ +#endif /* TUPTOASTER_H */ diff --git a/src/include/access/twophase.h b/src/include/access/twophase.h index d03af5f2c2..99c6227714 100644 --- a/src/include/access/twophase.h +++ b/src/include/access/twophase.h @@ -57,4 +57,4 @@ extern void PrepareRedoAdd(char *buf, XLogRecPtr start_lsn, XLogRecPtr end_lsn); extern void PrepareRedoRemove(TransactionId xid, bool giveWarning); extern void restoreTwoPhaseData(void); -#endif /* TWOPHASE_H */ +#endif /* TWOPHASE_H */ diff --git a/src/include/access/twophase_rmgr.h b/src/include/access/twophase_rmgr.h index 32b6475dd9..44cd6d202f 100644 --- a/src/include/access/twophase_rmgr.h +++ b/src/include/access/twophase_rmgr.h @@ -15,7 +15,7 @@ #define TWOPHASE_RMGR_H typedef void (*TwoPhaseCallback) (TransactionId xid, uint16 info, - void *recdata, uint32 len); + void *recdata, uint32 len); typedef uint8 TwoPhaseRmgrId; /* @@ -37,4 +37,4 @@ extern const TwoPhaseCallback twophase_standby_recover_callbacks[]; extern void RegisterTwoPhaseRecord(TwoPhaseRmgrId rmid, uint16 info, const void *data, uint32 len); -#endif /* TWOPHASE_RMGR_H */ +#endif /* TWOPHASE_RMGR_H */ diff --git a/src/include/access/valid.h b/src/include/access/valid.h index 72f2bb6ac2..53a7d0685a 100644 --- a/src/include/access/valid.h +++ b/src/include/access/valid.h @@ -66,4 +66,4 @@ do \ } \ } while (0) -#endif /* VALID_H */ +#endif /* VALID_H */ diff --git a/src/include/access/visibilitymap.h b/src/include/access/visibilitymap.h index a3796f2902..da0e76d6be 100644 --- a/src/include/access/visibilitymap.h +++ b/src/include/access/visibilitymap.h @@ -25,8 +25,8 @@ /* Flags for bit map */ #define VISIBILITYMAP_ALL_VISIBLE 0x01 #define VISIBILITYMAP_ALL_FROZEN 0x02 -#define VISIBILITYMAP_VALID_BITS 0x03 /* OR of all valid - * visibilitymap flags bits */ +#define VISIBILITYMAP_VALID_BITS 0x03 /* OR of all valid visibilitymap + * flags bits */ /* Macros for visibilitymap test */ #define VM_ALL_VISIBLE(r, b, v) \ @@ -46,4 +46,4 @@ extern uint8 visibilitymap_get_status(Relation rel, BlockNumber heapBlk, Buffer extern void visibilitymap_count(Relation rel, BlockNumber *all_visible, BlockNumber *all_frozen); extern void visibilitymap_truncate(Relation rel, BlockNumber nheapblocks); -#endif /* VISIBILITYMAP_H */ +#endif /* VISIBILITYMAP_H */ diff --git a/src/include/access/xact.h b/src/include/access/xact.h index 2186e706a6..16b3c5a26f 100644 --- a/src/include/access/xact.h +++ b/src/include/access/xact.h @@ -62,13 +62,12 @@ extern bool XactDeferrable; typedef enum { SYNCHRONOUS_COMMIT_OFF, /* asynchronous commit */ - SYNCHRONOUS_COMMIT_LOCAL_FLUSH, /* wait for local flush only */ + SYNCHRONOUS_COMMIT_LOCAL_FLUSH, /* wait for local flush only */ SYNCHRONOUS_COMMIT_REMOTE_WRITE, /* wait for local flush and remote * write */ SYNCHRONOUS_COMMIT_REMOTE_FLUSH, /* wait for local and remote flush */ - SYNCHRONOUS_COMMIT_REMOTE_APPLY /* wait for local flush and remote - * apply */ -} SyncCommitLevel; + SYNCHRONOUS_COMMIT_REMOTE_APPLY /* wait for local flush and remote apply */ +} SyncCommitLevel; /* Define the default setting for synchronous_commit */ #define SYNCHRONOUS_COMMIT_ON SYNCHRONOUS_COMMIT_REMOTE_FLUSH @@ -124,7 +123,7 @@ typedef enum } SubXactEvent; typedef void (*SubXactCallback) (SubXactEvent event, SubTransactionId mySubid, - SubTransactionId parentSubid, void *arg); + SubTransactionId parentSubid, void *arg); #ifdef PGXC /* @@ -460,4 +459,4 @@ extern void EnterParallelMode(void); extern void ExitParallelMode(void); extern bool IsInParallelMode(void); -#endif /* XACT_H */ +#endif /* XACT_H */ diff --git a/src/include/access/xlog.h b/src/include/access/xlog.h index 4a633a7fad..50e8ed4b17 100644 --- a/src/include/access/xlog.h +++ b/src/include/access/xlog.h @@ -24,9 +24,9 @@ /* Sync methods */ #define SYNC_METHOD_FSYNC 0 #define SYNC_METHOD_FDATASYNC 1 -#define SYNC_METHOD_OPEN 2 /* for O_SYNC */ +#define SYNC_METHOD_OPEN 2 /* for O_SYNC */ #define SYNC_METHOD_FSYNC_WRITETHROUGH 3 -#define SYNC_METHOD_OPEN_DSYNC 4 /* for O_DSYNC */ +#define SYNC_METHOD_OPEN_DSYNC 4 /* for O_DSYNC */ extern int sync_method; extern PGDLLIMPORT TimeLineID ThisTimeLineID; /* current TLI */ @@ -176,9 +176,8 @@ extern bool XLOG_DEBUG; /* These directly affect the behavior of CreateCheckPoint and subsidiaries */ #define CHECKPOINT_IS_SHUTDOWN 0x0001 /* Checkpoint is for shutdown */ -#define CHECKPOINT_END_OF_RECOVERY 0x0002 /* Like shutdown checkpoint, - * but issued at end of WAL - * recovery */ +#define CHECKPOINT_END_OF_RECOVERY 0x0002 /* Like shutdown checkpoint, but + * issued at end of WAL recovery */ #define CHECKPOINT_IMMEDIATE 0x0004 /* Do it without delays */ #define CHECKPOINT_FORCE 0x0008 /* Force even if no activity */ #define CHECKPOINT_FLUSH_ALL 0x0010 /* Flush all pages, including those @@ -205,18 +204,18 @@ typedef struct CheckpointStatsData TimestampTz ckpt_sync_end_t; /* end of fsyncs */ TimestampTz ckpt_end_t; /* end of checkpoint */ - int ckpt_bufs_written; /* # of buffers written */ + int ckpt_bufs_written; /* # of buffers written */ int ckpt_segs_added; /* # of new xlog segments created */ - int ckpt_segs_removed; /* # of xlog segments deleted */ - int ckpt_segs_recycled; /* # of xlog segments recycled */ + int ckpt_segs_removed; /* # of xlog segments deleted */ + int ckpt_segs_recycled; /* # of xlog segments recycled */ int ckpt_sync_rels; /* # of relations synced */ - uint64 ckpt_longest_sync; /* Longest sync for one relation */ - uint64 ckpt_agg_sync_time; /* The sum of all the individual sync - * times, which is not necessarily the - * same as the total elapsed time for - * the entire sync phase. */ + uint64 ckpt_longest_sync; /* Longest sync for one relation */ + uint64 ckpt_agg_sync_time; /* The sum of all the individual sync + * times, which is not necessarily the + * same as the total elapsed time for the + * entire sync phase. */ } CheckpointStatsData; extern CheckpointStatsData CheckpointStats; @@ -312,8 +311,8 @@ typedef enum SessionBackupState } SessionBackupState; extern XLogRecPtr do_pg_start_backup(const char *backupidstr, bool fast, - TimeLineID *starttli_p, StringInfo labelfile, DIR *tblspcdir, - List **tablespaces, StringInfo tblspcmapfile, bool infotbssize, + TimeLineID *starttli_p, StringInfo labelfile, DIR *tblspcdir, + List **tablespaces, StringInfo tblspcmapfile, bool infotbssize, bool needtblspcmapfile); extern XLogRecPtr do_pg_stop_backup(char *labelfile, bool waitforarchive, TimeLineID *stoptli_p); @@ -327,4 +326,4 @@ extern SessionBackupState get_backup_status(void); #define TABLESPACE_MAP "tablespace_map" #define TABLESPACE_MAP_OLD "tablespace_map.old" -#endif /* XLOG_H */ +#endif /* XLOG_H */ diff --git a/src/include/access/xlog_internal.h b/src/include/access/xlog_internal.h index 6e2bfd0ad0..a661ec0180 100644 --- a/src/include/access/xlog_internal.h +++ b/src/include/access/xlog_internal.h @@ -319,4 +319,4 @@ extern bool XLogArchiveIsReady(const char *xlog); extern bool XLogArchiveIsReadyOrDone(const char *xlog); extern void XLogArchiveCleanup(const char *xlog); -#endif /* XLOG_INTERNAL_H */ +#endif /* XLOG_INTERNAL_H */ diff --git a/src/include/access/xlogdefs.h b/src/include/access/xlogdefs.h index 0f07bb2674..3a80d6be6f 100644 --- a/src/include/access/xlogdefs.h +++ b/src/include/access/xlogdefs.h @@ -99,4 +99,4 @@ typedef uint16 RepOriginId; #define DEFAULT_SYNC_METHOD SYNC_METHOD_FSYNC #endif -#endif /* XLOG_DEFS_H */ +#endif /* XLOG_DEFS_H */ diff --git a/src/include/access/xloginsert.h b/src/include/access/xloginsert.h index d30786fa0d..174c88677f 100644 --- a/src/include/access/xloginsert.h +++ b/src/include/access/xloginsert.h @@ -29,14 +29,13 @@ /* flags for XLogRegisterBuffer */ #define REGBUF_FORCE_IMAGE 0x01 /* force a full-page image */ #define REGBUF_NO_IMAGE 0x02 /* don't take a full-page image */ -#define REGBUF_WILL_INIT (0x04 | 0x02) /* page will be re-initialized - * at replay (implies - * NO_IMAGE) */ -#define REGBUF_STANDARD 0x08/* page follows "standard" page layout, (data - * between pd_lower and pd_upper will be - * skipped) */ -#define REGBUF_KEEP_DATA 0x10/* include data even if a full-page image is - * taken */ +#define REGBUF_WILL_INIT (0x04 | 0x02) /* page will be re-initialized at + * replay (implies NO_IMAGE) */ +#define REGBUF_STANDARD 0x08 /* page follows "standard" page layout, + * (data between pd_lower and pd_upper + * will be skipped) */ +#define REGBUF_KEEP_DATA 0x10 /* include data even if a full-page image + * is taken */ /* prototypes for public functions in xloginsert.c: */ extern void XLogBeginInsert(void); @@ -59,4 +58,4 @@ extern XLogRecPtr XLogSaveBufferForHint(Buffer buffer, bool buffer_std); extern void InitXLogInsert(void); -#endif /* XLOGINSERT_H */ +#endif /* XLOGINSERT_H */ diff --git a/src/include/access/xlogreader.h b/src/include/access/xlogreader.h index 956c9bd3a8..7671598334 100644 --- a/src/include/access/xlogreader.h +++ b/src/include/access/xlogreader.h @@ -31,11 +31,11 @@ typedef struct XLogReaderState XLogReaderState; /* Function type definition for the read_page callback */ typedef int (*XLogPageReadCB) (XLogReaderState *xlogreader, - XLogRecPtr targetPagePtr, - int reqLen, - XLogRecPtr targetRecPtr, - char *readBuf, - TimeLineID *pageTLI); + XLogRecPtr targetPagePtr, + int reqLen, + XLogRecPtr targetRecPtr, + char *readBuf, + TimeLineID *pageTLI); typedef struct { @@ -204,7 +204,7 @@ extern void XLogReaderInvalReadState(XLogReaderState *state); #ifdef FRONTEND extern XLogRecPtr XLogFindNextRecord(XLogReaderState *state, XLogRecPtr RecPtr); -#endif /* FRONTEND */ +#endif /* FRONTEND */ /* Functions for decoding an XLogRecord */ @@ -233,4 +233,4 @@ extern bool XLogRecGetBlockTag(XLogReaderState *record, uint8 block_id, RelFileNode *rnode, ForkNumber *forknum, BlockNumber *blknum); -#endif /* XLOGREADER_H */ +#endif /* XLOGREADER_H */ diff --git a/src/include/access/xlogrecord.h b/src/include/access/xlogrecord.h index eeb6a30c1c..b53960e112 100644 --- a/src/include/access/xlogrecord.h +++ b/src/include/access/xlogrecord.h @@ -145,8 +145,9 @@ typedef struct XLogRecordBlockImageHeader /* Information stored in bimg_info */ #define BKPIMAGE_HAS_HOLE 0x01 /* page image has "hole" */ -#define BKPIMAGE_IS_COMPRESSED 0x02 /* page image is compressed */ -#define BKPIMAGE_APPLY 0x04 /* page image should be restored during replay */ +#define BKPIMAGE_IS_COMPRESSED 0x02 /* page image is compressed */ +#define BKPIMAGE_APPLY 0x04 /* page image should be restored during + * replay */ /* * Extra header information used when page image has "hole" and @@ -195,7 +196,7 @@ typedef struct XLogRecordDataHeaderShort { uint8 id; /* XLR_BLOCK_ID_DATA_SHORT */ uint8 data_length; /* number of payload bytes */ -} XLogRecordDataHeaderShort; +} XLogRecordDataHeaderShort; #define SizeOfXLogRecordDataHeaderShort (sizeof(uint8) * 2) @@ -203,7 +204,7 @@ typedef struct XLogRecordDataHeaderLong { uint8 id; /* XLR_BLOCK_ID_DATA_LONG */ /* followed by uint32 data_length, unaligned */ -} XLogRecordDataHeaderLong; +} XLogRecordDataHeaderLong; #define SizeOfXLogRecordDataHeaderLong (sizeof(uint8) + sizeof(uint32)) @@ -224,4 +225,4 @@ typedef struct XLogRecordDataHeaderLong #define XLR_BLOCK_ID_DATA_LONG 254 #define XLR_BLOCK_ID_ORIGIN 253 -#endif /* XLOGRECORD_H */ +#endif /* XLOGRECORD_H */ diff --git a/src/include/bootstrap/bootstrap.h b/src/include/bootstrap/bootstrap.h index 51a0ba925f..8903baada3 100644 --- a/src/include/bootstrap/bootstrap.h +++ b/src/include/bootstrap/bootstrap.h @@ -64,4 +64,4 @@ extern int boot_yyparse(void); extern int boot_yylex(void); extern void boot_yyerror(const char *str) pg_attribute_noreturn(); -#endif /* BOOTSTRAP_H */ +#endif /* BOOTSTRAP_H */ diff --git a/src/include/c.h b/src/include/c.h index 5e91b64305..3d58771b36 100644 --- a/src/include/c.h +++ b/src/include/c.h @@ -62,7 +62,7 @@ #define WIN32 #endif -#if !defined(WIN32) && !defined(__CYGWIN__) /* win32 includes further down */ +#if !defined(WIN32) && !defined(__CYGWIN__) /* win32 includes further down */ #include "pg_config_os.h" /* must be before any system header files */ #endif @@ -209,7 +209,7 @@ typedef char bool; #ifndef false #define false ((bool) 0) #endif -#endif /* not C++ */ +#endif /* not C++ */ typedef bool *BoolPtr; @@ -254,7 +254,7 @@ typedef char *Pointer; typedef signed char int8; /* == 8 bits */ typedef signed short int16; /* == 16 bits */ typedef signed int int32; /* == 32 bits */ -#endif /* not HAVE_INT8 */ +#endif /* not HAVE_INT8 */ /* * uintN @@ -266,7 +266,7 @@ typedef signed int int32; /* == 32 bits */ typedef unsigned char uint8; /* == 8 bits */ typedef unsigned short uint16; /* == 16 bits */ typedef unsigned int uint32; /* == 32 bits */ -#endif /* not HAVE_UINT8 */ +#endif /* not HAVE_UINT8 */ /* * bitsN @@ -420,7 +420,7 @@ typedef uint32 CommandId; typedef struct { int indx[MAXDIM]; -} IntArray; +} IntArray; /* ---------------- * Variable-length datatypes all share the 'struct varlena' header. @@ -553,7 +553,7 @@ typedef NameData *Name; */ #ifndef offsetof #define offsetof(type, field) ((long) &((type *)0)->field) -#endif /* offsetof */ +#endif /* offsetof */ /* * lengthof @@ -732,7 +732,7 @@ typedef NameData *Name; Trap(TYPEALIGN(bndr, (uintptr_t)(ptr)) != (uintptr_t)(ptr), \ "UnalignedPointer") -#endif /* USE_ASSERT_CHECKING && !FRONTEND */ +#endif /* USE_ASSERT_CHECKING && !FRONTEND */ /* * Macros to support compile-time assertion checks. @@ -758,7 +758,7 @@ typedef NameData *Name; ((void) sizeof(struct { int static_assert_failure : (condition) ? 1 : -1; })) #define StaticAssertExpr(condition, errmessage) \ StaticAssertStmt(condition, errmessage) -#endif /* HAVE__STATIC_ASSERT */ +#endif /* HAVE__STATIC_ASSERT */ /* @@ -786,7 +786,7 @@ typedef NameData *Name; #define AssertVariableIsOfTypeMacro(varname, typename) \ ((void) StaticAssertExpr(sizeof(varname) == sizeof(typename), \ CppAsString(varname) " does not have type " CppAsString(typename))) -#endif /* HAVE__BUILTIN_TYPES_COMPATIBLE_P */ +#endif /* HAVE__BUILTIN_TYPES_COMPATIBLE_P */ /* ---------------------------------------------------------------- @@ -1126,4 +1126,4 @@ extern int fdatasync(int fildes); /* /port compatibility functions */ #include "port.h" -#endif /* C_H */ +#endif /* C_H */ diff --git a/src/include/catalog/binary_upgrade.h b/src/include/catalog/binary_upgrade.h index 98089e3c1a..5ff365fe53 100644 --- a/src/include/catalog/binary_upgrade.h +++ b/src/include/catalog/binary_upgrade.h @@ -27,4 +27,4 @@ extern PGDLLIMPORT Oid binary_upgrade_next_pg_authid_oid; extern PGDLLIMPORT bool binary_upgrade_record_init_privs; -#endif /* BINARY_UPGRADE_H */ +#endif /* BINARY_UPGRADE_H */ diff --git a/src/include/catalog/catalog.h b/src/include/catalog/catalog.h index 7062d7ed2f..85d8385b3f 100644 --- a/src/include/catalog/catalog.h +++ b/src/include/catalog/catalog.h @@ -49,4 +49,4 @@ extern Oid GetNewOidWithIndex(Relation relation, Oid indexId, extern Oid GetNewRelFileNode(Oid reltablespace, Relation pg_class, char relpersistence); -#endif /* CATALOG_H */ +#endif /* CATALOG_H */ diff --git a/src/include/catalog/catversion.h b/src/include/catalog/catversion.h index 8b2ec21509..405e8e303b 100644 --- a/src/include/catalog/catversion.h +++ b/src/include/catalog/catversion.h @@ -53,6 +53,6 @@ */ /* yyyymmddN */ -#define CATALOG_VERSION_NO 201706141 +#define CATALOG_VERSION_NO 201706241 #endif diff --git a/src/include/catalog/dependency.h b/src/include/catalog/dependency.h index c4d0c694f4..f43bf41dbd 100644 --- a/src/include/catalog/dependency.h +++ b/src/include/catalog/dependency.h @@ -177,11 +177,11 @@ typedef enum ObjectClass #define LAST_OCLASS OCLASS_TRANSFORM /* flag bits for performDeletion/performMultipleDeletions: */ -#define PERFORM_DELETION_INTERNAL 0x0001 /* internal action */ -#define PERFORM_DELETION_CONCURRENTLY 0x0002 /* concurrent drop */ -#define PERFORM_DELETION_QUIETLY 0x0004 /* suppress notices */ -#define PERFORM_DELETION_SKIP_ORIGINAL 0x0008 /* keep original obj */ -#define PERFORM_DELETION_SKIP_EXTENSIONS 0x0010 /* keep extensions */ +#define PERFORM_DELETION_INTERNAL 0x0001 /* internal action */ +#define PERFORM_DELETION_CONCURRENTLY 0x0002 /* concurrent drop */ +#define PERFORM_DELETION_QUIETLY 0x0004 /* suppress notices */ +#define PERFORM_DELETION_SKIP_ORIGINAL 0x0008 /* keep original obj */ +#define PERFORM_DELETION_SKIP_EXTENSIONS 0x0010 /* keep extensions */ /* in dependency.c */ @@ -289,4 +289,4 @@ extern void shdepDropOwned(List *relids, DropBehavior behavior); extern void shdepReassignOwned(List *relids, Oid newrole); -#endif /* DEPENDENCY_H */ +#endif /* DEPENDENCY_H */ diff --git a/src/include/catalog/genbki.h b/src/include/catalog/genbki.h index a522b4cd82..a2cb313d4a 100644 --- a/src/include/catalog/genbki.h +++ b/src/include/catalog/genbki.h @@ -47,4 +47,4 @@ #define DESCR(x) extern int no_such_variable #define SHDESCR(x) extern int no_such_variable -#endif /* GENBKI_H */ +#endif /* GENBKI_H */ diff --git a/src/include/catalog/heap.h b/src/include/catalog/heap.h index 12ad62532b..3ac2a05159 100644 --- a/src/include/catalog/heap.h +++ b/src/include/catalog/heap.h @@ -166,4 +166,4 @@ extern void RemovePartitionKeyByRelId(Oid relid); extern void StorePartitionBound(Relation rel, Relation parent, PartitionBoundSpec *bound); -#endif /* HEAP_H */ +#endif /* HEAP_H */ diff --git a/src/include/catalog/index.h b/src/include/catalog/index.h index 20bec90b9d..1d4ec09f8f 100644 --- a/src/include/catalog/index.h +++ b/src/include/catalog/index.h @@ -22,11 +22,11 @@ /* Typedef for callback function for IndexBuildHeapScan */ typedef void (*IndexBuildCallback) (Relation index, - HeapTuple htup, - Datum *values, - bool *isnull, - bool tupleIsAlive, - void *state); + HeapTuple htup, + Datum *values, + bool *isnull, + bool tupleIsAlive, + void *state); /* Action code for index_set_state_flags */ typedef enum @@ -131,4 +131,4 @@ extern bool ReindexIsProcessingHeap(Oid heapOid); extern bool ReindexIsProcessingIndex(Oid indexOid); extern Oid IndexGetRelation(Oid indexId, bool missing_ok); -#endif /* INDEX_H */ +#endif /* INDEX_H */ diff --git a/src/include/catalog/indexing.h b/src/include/catalog/indexing.h index 35f50b69a5..2039d86962 100644 --- a/src/include/catalog/indexing.h +++ b/src/include/catalog/indexing.h @@ -384,4 +384,4 @@ DECLARE_UNIQUE_INDEX(pg_subscription_rel_srrelid_srsubid_index, 6117, on pg_subs /* last step of initialization script: build the indexes declared above */ BUILD_INDICES -#endif /* INDEXING_H */ +#endif /* INDEXING_H */ diff --git a/src/include/catalog/namespace.h b/src/include/catalog/namespace.h index 14df88290a..074c315b4f 100644 --- a/src/include/catalog/namespace.h +++ b/src/include/catalog/namespace.h @@ -36,7 +36,7 @@ typedef struct _FuncCandidateList int ndargs; /* number of defaulted args */ int *argnumbers; /* args' positional indexes, if named call */ Oid args[FLEXIBLE_ARRAY_MEMBER]; /* arg types */ -} *FuncCandidateList; +} *FuncCandidateList; /* * Structure for xxxOverrideSearchPath functions @@ -49,7 +49,7 @@ typedef struct OverrideSearchPath } OverrideSearchPath; typedef void (*RangeVarGetRelidCallback) (const RangeVar *relation, Oid relId, - Oid oldRelId, void *callback_arg); + Oid oldRelId, void *callback_arg); #define RangeVarGetRelid(relation, lockmode, missing_ok) \ RangeVarGetRelidExtended(relation, lockmode, missing_ok, false, NULL, NULL) @@ -161,4 +161,4 @@ extern char *namespace_search_path; extern List *fetch_search_path(bool includeImplicit); extern int fetch_search_path_array(Oid *sarray, int sarray_len); -#endif /* NAMESPACE_H */ +#endif /* NAMESPACE_H */ diff --git a/src/include/catalog/objectaccess.h b/src/include/catalog/objectaccess.h index 3a6dd596ce..251eb6fd88 100644 --- a/src/include/catalog/objectaccess.h +++ b/src/include/catalog/objectaccess.h @@ -118,10 +118,10 @@ typedef struct /* Plugin provides a hook function matching this signature. */ typedef void (*object_access_hook_type) (ObjectAccessType access, - Oid classId, - Oid objectId, - int subId, - void *arg); + Oid classId, + Oid objectId, + int subId, + void *arg); /* Plugin sets this variable to a suitable hook function. */ extern PGDLLIMPORT object_access_hook_type object_access_hook; @@ -182,4 +182,4 @@ extern void RunFunctionExecuteHook(Oid objectId); RunFunctionExecuteHook(objectId); \ } while(0) -#endif /* OBJECTACCESS_H */ +#endif /* OBJECTACCESS_H */ diff --git a/src/include/catalog/objectaddress.h b/src/include/catalog/objectaddress.h index 406c38bc73..5fc54d0e57 100644 --- a/src/include/catalog/objectaddress.h +++ b/src/include/catalog/objectaddress.h @@ -78,4 +78,4 @@ extern char *getObjectIdentityParts(const ObjectAddress *address, List **objname, List **objargs); extern ArrayType *strlist_to_textarray(List *list); -#endif /* OBJECTADDRESS_H */ +#endif /* OBJECTADDRESS_H */ diff --git a/src/include/catalog/opfam_internal.h b/src/include/catalog/opfam_internal.h index 448ad9708b..c4a010029a 100644 --- a/src/include/catalog/opfam_internal.h +++ b/src/include/catalog/opfam_internal.h @@ -25,4 +25,4 @@ typedef struct Oid sortfamily; /* ordering operator's sort opfamily, or 0 */ } OpFamilyMember; -#endif /* OPFAM_INTERNAL_H */ +#endif /* OPFAM_INTERNAL_H */ diff --git a/src/include/catalog/partition.h b/src/include/catalog/partition.h index 0a1e468898..f10879a162 100644 --- a/src/include/catalog/partition.h +++ b/src/include/catalog/partition.h @@ -34,7 +34,7 @@ typedef struct PartitionDescData { int nparts; /* Number of partitions */ Oid *oids; /* OIDs of partitions */ - PartitionBoundInfo boundinfo; /* collection of partition bounds */ + PartitionBoundInfo boundinfo; /* collection of partition bounds */ } PartitionDescData; typedef struct PartitionDescData *PartitionDesc; @@ -98,4 +98,4 @@ extern int get_partition_for_tuple(PartitionDispatch *pd, EState *estate, PartitionDispatchData **failed_at, TupleTableSlot **failed_slot); -#endif /* PARTITION_H */ +#endif /* PARTITION_H */ diff --git a/src/include/catalog/pg_aggregate.h b/src/include/catalog/pg_aggregate.h index 1ffde6cdc5..4d5b9bb9a6 100644 --- a/src/include/catalog/pg_aggregate.h +++ b/src/include/catalog/pg_aggregate.h @@ -348,4 +348,4 @@ extern ObjectAddress AggregateCreate(const char *aggName, const char *aggminitval, char proparallel); -#endif /* PG_AGGREGATE_H */ +#endif /* PG_AGGREGATE_H */ diff --git a/src/include/catalog/pg_am.h b/src/include/catalog/pg_am.h index 9b6dc38f64..e021f5b894 100644 --- a/src/include/catalog/pg_am.h +++ b/src/include/catalog/pg_am.h @@ -58,7 +58,7 @@ typedef FormData_pg_am *Form_pg_am; * compiler constant for amtype * ---------------- */ -#define AMTYPE_INDEX 'i' /* index access method */ +#define AMTYPE_INDEX 'i' /* index access method */ /* ---------------- * initial contents of pg_am @@ -84,4 +84,4 @@ DATA(insert OID = 3580 ( brin brinhandler i )); DESCR("block range index (BRIN) access method"); #define BRIN_AM_OID 3580 -#endif /* PG_AM_H */ +#endif /* PG_AM_H */ diff --git a/src/include/catalog/pg_amop.h b/src/include/catalog/pg_amop.h index da0228de6b..f850be490a 100644 --- a/src/include/catalog/pg_amop.h +++ b/src/include/catalog/pg_amop.h @@ -1162,4 +1162,4 @@ DATA(insert ( 4104 603 603 12 s 2572 3580 0 )); /* we could, but choose not to, supply entries for strategies 13 and 14 */ DATA(insert ( 4104 603 600 7 s 433 3580 0 )); -#endif /* PG_AMOP_H */ +#endif /* PG_AMOP_H */ diff --git a/src/include/catalog/pg_amproc.h b/src/include/catalog/pg_amproc.h index bcbb7a1617..7d245b1271 100644 --- a/src/include/catalog/pg_amproc.h +++ b/src/include/catalog/pg_amproc.h @@ -536,4 +536,4 @@ DATA(insert ( 4104 603 603 4 4108 )); DATA(insert ( 4104 603 603 11 4067 )); DATA(insert ( 4104 603 603 13 187 )); -#endif /* PG_AMPROC_H */ +#endif /* PG_AMPROC_H */ diff --git a/src/include/catalog/pg_attrdef.h b/src/include/catalog/pg_attrdef.h index ff1842f53c..b877f42a2d 100644 --- a/src/include/catalog/pg_attrdef.h +++ b/src/include/catalog/pg_attrdef.h @@ -56,4 +56,4 @@ typedef FormData_pg_attrdef *Form_pg_attrdef; #define Anum_pg_attrdef_adbin 3 #define Anum_pg_attrdef_adsrc 4 -#endif /* PG_ATTRDEF_H */ +#endif /* PG_ATTRDEF_H */ diff --git a/src/include/catalog/pg_attribute.h b/src/include/catalog/pg_attribute.h index 753d45f2d1..bcf28e8f04 100644 --- a/src/include/catalog/pg_attribute.h +++ b/src/include/catalog/pg_attribute.h @@ -228,4 +228,4 @@ typedef FormData_pg_attribute *Form_pg_attribute; #define ATTRIBUTE_IDENTITY_ALWAYS 'a' #define ATTRIBUTE_IDENTITY_BY_DEFAULT 'd' -#endif /* PG_ATTRIBUTE_H */ +#endif /* PG_ATTRIBUTE_H */ diff --git a/src/include/catalog/pg_auth_members.h b/src/include/catalog/pg_auth_members.h index e34a4e80a4..6a954fff97 100644 --- a/src/include/catalog/pg_auth_members.h +++ b/src/include/catalog/pg_auth_members.h @@ -54,4 +54,4 @@ typedef FormData_pg_auth_members *Form_pg_auth_members; #define Anum_pg_auth_members_grantor 3 #define Anum_pg_auth_members_admin_option 4 -#endif /* PG_AUTH_MEMBERS_H */ +#endif /* PG_AUTH_MEMBERS_H */ diff --git a/src/include/catalog/pg_authid.h b/src/include/catalog/pg_authid.h index 39fea9f41a..9b6b52c9f9 100644 --- a/src/include/catalog/pg_authid.h +++ b/src/include/catalog/pg_authid.h @@ -111,4 +111,4 @@ DATA(insert OID = 3377 ( "pg_stat_scan_tables" f t f f f f f -1 _null_ _null_)); DATA(insert OID = 4200 ( "pg_signal_backend" f t f f f f f -1 _null_ _null_)); #define DEFAULT_ROLE_SIGNAL_BACKENDID 4200 -#endif /* PG_AUTHID_H */ +#endif /* PG_AUTHID_H */ diff --git a/src/include/catalog/pg_cast.h b/src/include/catalog/pg_cast.h index ccc6fb35a8..17827531ad 100644 --- a/src/include/catalog/pg_cast.h +++ b/src/include/catalog/pg_cast.h @@ -52,8 +52,8 @@ typedef FormData_pg_cast *Form_pg_cast; typedef enum CoercionCodes { - COERCION_CODE_IMPLICIT = 'i', /* coercion in context of expression */ - COERCION_CODE_ASSIGNMENT = 'a', /* coercion in context of assignment */ + COERCION_CODE_IMPLICIT = 'i', /* coercion in context of expression */ + COERCION_CODE_ASSIGNMENT = 'a', /* coercion in context of assignment */ COERCION_CODE_EXPLICIT = 'e' /* explicit cast operation */ } CoercionCodes; @@ -64,8 +64,8 @@ typedef enum CoercionCodes */ typedef enum CoercionMethod { - COERCION_METHOD_FUNCTION = 'f', /* use a function */ - COERCION_METHOD_BINARY = 'b', /* types are binary-compatible */ + COERCION_METHOD_FUNCTION = 'f', /* use a function */ + COERCION_METHOD_BINARY = 'b', /* types are binary-compatible */ COERCION_METHOD_INOUT = 'i' /* use input/output functions */ } CoercionMethod; @@ -392,4 +392,4 @@ DATA(insert ( 1700 1700 1703 i f )); DATA(insert ( 114 3802 0 a i )); DATA(insert ( 3802 114 0 a i )); -#endif /* PG_CAST_H */ +#endif /* PG_CAST_H */ diff --git a/src/include/catalog/pg_class.h b/src/include/catalog/pg_class.h index 3657201317..04c163042c 100644 --- a/src/include/catalog/pg_class.h +++ b/src/include/catalog/pg_class.h @@ -157,19 +157,19 @@ DATA(insert OID = 1259 ( pg_class PGNSP 83 0 PGUID 0 0 0 0 0 0 0 f f p r 33 0 DESCR(""); -#define RELKIND_RELATION 'r' /* ordinary table */ -#define RELKIND_INDEX 'i' /* secondary index */ -#define RELKIND_SEQUENCE 'S' /* sequence object */ -#define RELKIND_TOASTVALUE 't' /* for out-of-line values */ -#define RELKIND_VIEW 'v' /* view */ -#define RELKIND_MATVIEW 'm' /* materialized view */ -#define RELKIND_COMPOSITE_TYPE 'c' /* composite type */ -#define RELKIND_FOREIGN_TABLE 'f' /* foreign table */ -#define RELKIND_PARTITIONED_TABLE 'p' /* partitioned table */ - -#define RELPERSISTENCE_PERMANENT 'p' /* regular table */ -#define RELPERSISTENCE_UNLOGGED 'u' /* unlogged permanent table */ -#define RELPERSISTENCE_TEMP 't' /* temporary table */ +#define RELKIND_RELATION 'r' /* ordinary table */ +#define RELKIND_INDEX 'i' /* secondary index */ +#define RELKIND_SEQUENCE 'S' /* sequence object */ +#define RELKIND_TOASTVALUE 't' /* for out-of-line values */ +#define RELKIND_VIEW 'v' /* view */ +#define RELKIND_MATVIEW 'm' /* materialized view */ +#define RELKIND_COMPOSITE_TYPE 'c' /* composite type */ +#define RELKIND_FOREIGN_TABLE 'f' /* foreign table */ +#define RELKIND_PARTITIONED_TABLE 'p' /* partitioned table */ + +#define RELPERSISTENCE_PERMANENT 'p' /* regular table */ +#define RELPERSISTENCE_UNLOGGED 'u' /* unlogged permanent table */ +#define RELPERSISTENCE_TEMP 't' /* temporary table */ #ifdef PGXC #define RELPERSISTENCE_LOCAL_TEMP 'l' /* local temp table */ @@ -188,4 +188,4 @@ DESCR(""); */ #define REPLICA_IDENTITY_INDEX 'i' -#endif /* PG_CLASS_H */ +#endif /* PG_CLASS_H */ diff --git a/src/include/catalog/pg_collation.h b/src/include/catalog/pg_collation.h index 901c0b5115..0cac7cae72 100644 --- a/src/include/catalog/pg_collation.h +++ b/src/include/catalog/pg_collation.h @@ -85,4 +85,4 @@ DESCR("standard POSIX collation"); #define COLLPROVIDER_ICU 'i' #define COLLPROVIDER_LIBC 'c' -#endif /* PG_COLLATION_H */ +#endif /* PG_COLLATION_H */ diff --git a/src/include/catalog/pg_collation_fn.h b/src/include/catalog/pg_collation_fn.h index dfebdbaa0b..0ef31389d5 100644 --- a/src/include/catalog/pg_collation_fn.h +++ b/src/include/catalog/pg_collation_fn.h @@ -20,7 +20,8 @@ extern Oid CollationCreate(const char *collname, Oid collnamespace, int32 collencoding, const char *collcollate, const char *collctype, const char *collversion, - bool if_not_exists); + bool if_not_exists, + bool quiet); extern void RemoveCollationById(Oid collationOid); -#endif /* PG_COLLATION_FN_H */ +#endif /* PG_COLLATION_FN_H */ diff --git a/src/include/catalog/pg_constraint.h b/src/include/catalog/pg_constraint.h index e959583364..ec035d8434 100644 --- a/src/include/catalog/pg_constraint.h +++ b/src/include/catalog/pg_constraint.h @@ -198,4 +198,4 @@ typedef FormData_pg_constraint *Form_pg_constraint; * the FKCONSTR_MATCH_xxx constants defined in parsenodes.h. */ -#endif /* PG_CONSTRAINT_H */ +#endif /* PG_CONSTRAINT_H */ diff --git a/src/include/catalog/pg_constraint_fn.h b/src/include/catalog/pg_constraint_fn.h index d2acb3a053..a4c46897ed 100644 --- a/src/include/catalog/pg_constraint_fn.h +++ b/src/include/catalog/pg_constraint_fn.h @@ -67,7 +67,7 @@ extern char *ChooseConstraintName(const char *name1, const char *name2, List *others); extern void AlterConstraintNamespaces(Oid ownerId, Oid oldNspId, - Oid newNspId, bool isType, ObjectAddresses *objsMoved); + Oid newNspId, bool isType, ObjectAddresses *objsMoved); extern Oid get_relation_constraint_oid(Oid relid, const char *conname, bool missing_ok); extern Oid get_domain_constraint_oid(Oid typid, const char *conname, bool missing_ok); @@ -79,4 +79,4 @@ extern bool check_functional_grouping(Oid relid, List *grouping_columns, List **constraintDeps); -#endif /* PG_CONSTRAINT_FN_H */ +#endif /* PG_CONSTRAINT_FN_H */ diff --git a/src/include/catalog/pg_control.h b/src/include/catalog/pg_control.h index 3a25cc84b2..84327c9da6 100644 --- a/src/include/catalog/pg_control.h +++ b/src/include/catalog/pg_control.h @@ -121,8 +121,8 @@ typedef struct ControlFileData * example, WAL logs contain per-page magic numbers that can serve as * version cues for the WAL log. */ - uint32 pg_control_version; /* PG_CONTROL_VERSION */ - uint32 catalog_version_no; /* see catversion.h */ + uint32 pg_control_version; /* PG_CONTROL_VERSION */ + uint32 catalog_version_no; /* see catversion.h */ /* * System status data @@ -244,4 +244,4 @@ typedef struct ControlFileData */ #define PG_CONTROL_SIZE 8192 -#endif /* PG_CONTROL_H */ +#endif /* PG_CONTROL_H */ diff --git a/src/include/catalog/pg_conversion.h b/src/include/catalog/pg_conversion.h index 88174a620a..0682d7eb22 100644 --- a/src/include/catalog/pg_conversion.h +++ b/src/include/catalog/pg_conversion.h @@ -74,4 +74,4 @@ typedef FormData_pg_conversion *Form_pg_conversion; * --------------- */ -#endif /* PG_CONVERSION_H */ +#endif /* PG_CONVERSION_H */ diff --git a/src/include/catalog/pg_conversion_fn.h b/src/include/catalog/pg_conversion_fn.h index a2c1345f01..7074bcf13a 100644 --- a/src/include/catalog/pg_conversion_fn.h +++ b/src/include/catalog/pg_conversion_fn.h @@ -24,4 +24,4 @@ extern ObjectAddress ConversionCreate(const char *conname, Oid connamespace, extern void RemoveConversionById(Oid conversionOid); extern Oid FindDefaultConversion(Oid connamespace, int32 for_encoding, int32 to_encoding); -#endif /* PG_CONVERSION_FN_H */ +#endif /* PG_CONVERSION_FN_H */ diff --git a/src/include/catalog/pg_database.h b/src/include/catalog/pg_database.h index 55a1f6edab..e7cbca49cf 100644 --- a/src/include/catalog/pg_database.h +++ b/src/include/catalog/pg_database.h @@ -79,4 +79,4 @@ DATA(insert OID = 1 ( template1 PGUID ENCODING "LC_COLLATE" "LC_CTYPE" t t -1 0 SHDESCR("default template for new databases"); #define TemplateDbOid 1 -#endif /* PG_DATABASE_H */ +#endif /* PG_DATABASE_H */ diff --git a/src/include/catalog/pg_db_role_setting.h b/src/include/catalog/pg_db_role_setting.h index 311258fd7b..4a8e3370c9 100644 --- a/src/include/catalog/pg_db_role_setting.h +++ b/src/include/catalog/pg_db_role_setting.h @@ -42,7 +42,7 @@ CATALOG(pg_db_role_setting,2964) BKI_SHARED_RELATION BKI_WITHOUT_OIDS #endif } FormData_pg_db_role_setting; -typedef FormData_pg_db_role_setting *Form_pg_db_role_setting; +typedef FormData_pg_db_role_setting * Form_pg_db_role_setting; /* ---------------- * compiler constants for pg_db_role_setting @@ -66,4 +66,4 @@ extern void DropSetting(Oid databaseid, Oid roleid); extern void ApplySetting(Snapshot snapshot, Oid databaseid, Oid roleid, Relation relsetting, GucSource source); -#endif /* PG_DB_ROLE_SETTING_H */ +#endif /* PG_DB_ROLE_SETTING_H */ diff --git a/src/include/catalog/pg_default_acl.h b/src/include/catalog/pg_default_acl.h index 78bbeb64fe..09587abee6 100644 --- a/src/include/catalog/pg_default_acl.h +++ b/src/include/catalog/pg_default_acl.h @@ -66,10 +66,10 @@ typedef FormData_pg_default_acl *Form_pg_default_acl; * permissions through pg_default_acl. These codes are used in the * defaclobjtype column. */ -#define DEFACLOBJ_RELATION 'r' /* table, view */ -#define DEFACLOBJ_SEQUENCE 'S' /* sequence */ -#define DEFACLOBJ_FUNCTION 'f' /* function */ -#define DEFACLOBJ_TYPE 'T' /* type */ -#define DEFACLOBJ_NAMESPACE 'n' /* namespace */ +#define DEFACLOBJ_RELATION 'r' /* table, view */ +#define DEFACLOBJ_SEQUENCE 'S' /* sequence */ +#define DEFACLOBJ_FUNCTION 'f' /* function */ +#define DEFACLOBJ_TYPE 'T' /* type */ +#define DEFACLOBJ_NAMESPACE 'n' /* namespace */ -#endif /* PG_DEFAULT_ACL_H */ +#endif /* PG_DEFAULT_ACL_H */ diff --git a/src/include/catalog/pg_depend.h b/src/include/catalog/pg_depend.h index 6c480dd7dc..8bda78d9ef 100644 --- a/src/include/catalog/pg_depend.h +++ b/src/include/catalog/pg_depend.h @@ -87,4 +87,4 @@ typedef FormData_pg_depend *Form_pg_depend; * convenient to find from the contents of other catalogs. */ -#endif /* PG_DEPEND_H */ +#endif /* PG_DEPEND_H */ diff --git a/src/include/catalog/pg_description.h b/src/include/catalog/pg_description.h index 2f51ac33f3..e0499ca2d6 100644 --- a/src/include/catalog/pg_description.h +++ b/src/include/catalog/pg_description.h @@ -52,7 +52,7 @@ CATALOG(pg_description,2609) BKI_WITHOUT_OIDS int32 objsubid; /* column number, or 0 if not used */ #ifdef CATALOG_VARLEN /* variable-length fields start here */ - text description BKI_FORCE_NOT_NULL; /* description of object */ + text description BKI_FORCE_NOT_NULL; /* description of object */ #endif } FormData_pg_description; @@ -61,7 +61,7 @@ CATALOG(pg_description,2609) BKI_WITHOUT_OIDS * the format of pg_description relation. * ---------------- */ -typedef FormData_pg_description *Form_pg_description; +typedef FormData_pg_description * Form_pg_description; /* ---------------- * compiler constants for pg_description @@ -84,4 +84,4 @@ typedef FormData_pg_description *Form_pg_description; * by genbki.pl and loaded during initdb. */ -#endif /* PG_DESCRIPTION_H */ +#endif /* PG_DESCRIPTION_H */ diff --git a/src/include/catalog/pg_enum.h b/src/include/catalog/pg_enum.h index faee5e6c3c..5938ba5cac 100644 --- a/src/include/catalog/pg_enum.h +++ b/src/include/catalog/pg_enum.h @@ -70,4 +70,4 @@ extern void AddEnumLabel(Oid enumTypeOid, const char *newVal, extern void RenameEnumLabel(Oid enumTypeOid, const char *oldVal, const char *newVal); -#endif /* PG_ENUM_H */ +#endif /* PG_ENUM_H */ diff --git a/src/include/catalog/pg_event_trigger.h b/src/include/catalog/pg_event_trigger.h index b41cc12602..f9f568b27b 100644 --- a/src/include/catalog/pg_event_trigger.h +++ b/src/include/catalog/pg_event_trigger.h @@ -61,4 +61,4 @@ typedef FormData_pg_event_trigger *Form_pg_event_trigger; #define Anum_pg_event_trigger_evtenabled 5 #define Anum_pg_event_trigger_evttags 6 -#endif /* PG_EVENT_TRIGGER_H */ +#endif /* PG_EVENT_TRIGGER_H */ diff --git a/src/include/catalog/pg_extension.h b/src/include/catalog/pg_extension.h index 41b087d8b9..2ce575d17e 100644 --- a/src/include/catalog/pg_extension.h +++ b/src/include/catalog/pg_extension.h @@ -37,7 +37,7 @@ CATALOG(pg_extension,3079) #ifdef CATALOG_VARLEN /* variable-length fields start here */ /* extversion may never be null, but the others can be. */ - text extversion BKI_FORCE_NOT_NULL; /* extension version name */ + text extversion BKI_FORCE_NOT_NULL; /* extension version name */ Oid extconfig[1]; /* dumpable configuration tables */ text extcondition[1]; /* WHERE clauses for config tables */ #endif @@ -69,4 +69,4 @@ typedef FormData_pg_extension *Form_pg_extension; * ---------------- */ -#endif /* PG_EXTENSION_H */ +#endif /* PG_EXTENSION_H */ diff --git a/src/include/catalog/pg_foreign_data_wrapper.h b/src/include/catalog/pg_foreign_data_wrapper.h index 47df6799c9..af602c74ee 100644 --- a/src/include/catalog/pg_foreign_data_wrapper.h +++ b/src/include/catalog/pg_foreign_data_wrapper.h @@ -61,4 +61,4 @@ typedef FormData_pg_foreign_data_wrapper *Form_pg_foreign_data_wrapper; #define Anum_pg_foreign_data_wrapper_fdwacl 5 #define Anum_pg_foreign_data_wrapper_fdwoptions 6 -#endif /* PG_FOREIGN_DATA_WRAPPER_H */ +#endif /* PG_FOREIGN_DATA_WRAPPER_H */ diff --git a/src/include/catalog/pg_foreign_server.h b/src/include/catalog/pg_foreign_server.h index 629bfc389d..689dbbb4e7 100644 --- a/src/include/catalog/pg_foreign_server.h +++ b/src/include/catalog/pg_foreign_server.h @@ -61,4 +61,4 @@ typedef FormData_pg_foreign_server *Form_pg_foreign_server; #define Anum_pg_foreign_server_srvacl 6 #define Anum_pg_foreign_server_srvoptions 7 -#endif /* PG_FOREIGN_SERVER_H */ +#endif /* PG_FOREIGN_SERVER_H */ diff --git a/src/include/catalog/pg_foreign_table.h b/src/include/catalog/pg_foreign_table.h index b62d5e948b..c5dbcceef1 100644 --- a/src/include/catalog/pg_foreign_table.h +++ b/src/include/catalog/pg_foreign_table.h @@ -53,4 +53,4 @@ typedef FormData_pg_foreign_table *Form_pg_foreign_table; #define Anum_pg_foreign_table_ftserver 2 #define Anum_pg_foreign_table_ftoptions 3 -#endif /* PG_FOREIGN_TABLE_H */ +#endif /* PG_FOREIGN_TABLE_H */ diff --git a/src/include/catalog/pg_index.h b/src/include/catalog/pg_index.h index 7ca0fae707..8505c3be5f 100644 --- a/src/include/catalog/pg_index.h +++ b/src/include/catalog/pg_index.h @@ -108,4 +108,4 @@ typedef FormData_pg_index *Form_pg_index; #define IndexIsReady(indexForm) ((indexForm)->indisready) #define IndexIsLive(indexForm) ((indexForm)->indislive) -#endif /* PG_INDEX_H */ +#endif /* PG_INDEX_H */ diff --git a/src/include/catalog/pg_inherits.h b/src/include/catalog/pg_inherits.h index 434fa7c864..26bfab5db6 100644 --- a/src/include/catalog/pg_inherits.h +++ b/src/include/catalog/pg_inherits.h @@ -56,4 +56,4 @@ typedef FormData_pg_inherits *Form_pg_inherits; * ---------------- */ -#endif /* PG_INHERITS_H */ +#endif /* PG_INHERITS_H */ diff --git a/src/include/catalog/pg_inherits_fn.h b/src/include/catalog/pg_inherits_fn.h index e33b39e71e..abfa4766a1 100644 --- a/src/include/catalog/pg_inherits_fn.h +++ b/src/include/catalog/pg_inherits_fn.h @@ -23,4 +23,4 @@ extern List *find_all_inheritors(Oid parentrelId, LOCKMODE lockmode, extern bool has_subclass(Oid relationId); extern bool typeInheritsFrom(Oid subclassTypeId, Oid superclassTypeId); -#endif /* PG_INHERITS_FN_H */ +#endif /* PG_INHERITS_FN_H */ diff --git a/src/include/catalog/pg_init_privs.h b/src/include/catalog/pg_init_privs.h index 0d241b8a40..5fca36334b 100644 --- a/src/include/catalog/pg_init_privs.h +++ b/src/include/catalog/pg_init_privs.h @@ -49,8 +49,7 @@ CATALOG(pg_init_privs,3394) BKI_WITHOUT_OIDS char privtype; /* from initdb or extension? */ #ifdef CATALOG_VARLEN /* variable-length fields start here */ - aclitem initprivs[1] BKI_FORCE_NOT_NULL; /* initial privs on - * object */ + aclitem initprivs[1] BKI_FORCE_NOT_NULL; /* initial privs on object */ #endif } FormData_pg_init_privs; @@ -59,7 +58,7 @@ CATALOG(pg_init_privs,3394) BKI_WITHOUT_OIDS * the format of pg_init_privs relation. * ---------------- */ -typedef FormData_pg_init_privs *Form_pg_init_privs; +typedef FormData_pg_init_privs * Form_pg_init_privs; /* ---------------- * compiler constants for pg_init_privs @@ -98,4 +97,4 @@ typedef enum InitPrivsType * The initial contents are loaded near the end of initdb. */ -#endif /* PG_INIT_PRIVS_H */ +#endif /* PG_INIT_PRIVS_H */ diff --git a/src/include/catalog/pg_language.h b/src/include/catalog/pg_language.h index 46e4099485..ad244e839b 100644 --- a/src/include/catalog/pg_language.h +++ b/src/include/catalog/pg_language.h @@ -79,4 +79,4 @@ DATA(insert OID = 14 ( "sql" PGUID f t 0 0 2248 _null_ )); DESCR("SQL-language functions"); #define SQLlanguageId 14 -#endif /* PG_LANGUAGE_H */ +#endif /* PG_LANGUAGE_H */ diff --git a/src/include/catalog/pg_largeobject.h b/src/include/catalog/pg_largeobject.h index 93c8c6af6e..f2df67c35f 100644 --- a/src/include/catalog/pg_largeobject.h +++ b/src/include/catalog/pg_largeobject.h @@ -34,7 +34,8 @@ CATALOG(pg_largeobject,2613) BKI_WITHOUT_OIDS int32 pageno; /* Page number (starting from 0) */ /* data has variable length, but we allow direct access; see inv_api.c */ - bytea data BKI_FORCE_NOT_NULL; /* Data for page (may be zero-length) */ + bytea data BKI_FORCE_NOT_NULL; /* Data for page (may be + * zero-length) */ } FormData_pg_largeobject; /* ---------------- @@ -57,4 +58,4 @@ extern Oid LargeObjectCreate(Oid loid); extern void LargeObjectDrop(Oid loid); extern bool LargeObjectExists(Oid loid); -#endif /* PG_LARGEOBJECT_H */ +#endif /* PG_LARGEOBJECT_H */ diff --git a/src/include/catalog/pg_largeobject_metadata.h b/src/include/catalog/pg_largeobject_metadata.h index 16cb602a6c..7ae6d8c02b 100644 --- a/src/include/catalog/pg_largeobject_metadata.h +++ b/src/include/catalog/pg_largeobject_metadata.h @@ -52,4 +52,4 @@ typedef FormData_pg_largeobject_metadata *Form_pg_largeobject_metadata; #define Anum_pg_largeobject_metadata_lomowner 1 #define Anum_pg_largeobject_metadata_lomacl 2 -#endif /* PG_LARGEOBJECT_METADATA_H */ +#endif /* PG_LARGEOBJECT_METADATA_H */ diff --git a/src/include/catalog/pg_namespace.h b/src/include/catalog/pg_namespace.h index 010190e35c..095c5154ae 100644 --- a/src/include/catalog/pg_namespace.h +++ b/src/include/catalog/pg_namespace.h @@ -88,4 +88,4 @@ DESCR("StormDB catalog schema"); */ extern Oid NamespaceCreate(const char *nspName, Oid ownerId, bool isTemp); -#endif /* PG_NAMESPACE_H */ +#endif /* PG_NAMESPACE_H */ diff --git a/src/include/catalog/pg_opclass.h b/src/include/catalog/pg_opclass.h index 5819d5309f..28dbc747d5 100644 --- a/src/include/catalog/pg_opclass.h +++ b/src/include/catalog/pg_opclass.h @@ -247,4 +247,4 @@ DATA(insert ( 3580 pg_lsn_minmax_ops PGNSP PGUID 4082 3220 t 3220 )); DATA(insert ( 3580 box_inclusion_ops PGNSP PGUID 4104 603 t 603 )); /* no brin opclass for the geometric types except box */ -#endif /* PG_OPCLASS_H */ +#endif /* PG_OPCLASS_H */ diff --git a/src/include/catalog/pg_operator.h b/src/include/catalog/pg_operator.h index ccbb17efec..ffabc2003b 100644 --- a/src/include/catalog/pg_operator.h +++ b/src/include/catalog/pg_operator.h @@ -1854,4 +1854,4 @@ DESCR("delete array element"); DATA(insert OID = 3287 ( "#-" PGNSP PGUID b f f 3802 1009 3802 0 0 jsonb_delete_path - - )); DESCR("delete path"); -#endif /* PG_OPERATOR_H */ +#endif /* PG_OPERATOR_H */ diff --git a/src/include/catalog/pg_operator_fn.h b/src/include/catalog/pg_operator_fn.h index d8ea390fdf..37f5c712fe 100644 --- a/src/include/catalog/pg_operator_fn.h +++ b/src/include/catalog/pg_operator_fn.h @@ -33,4 +33,4 @@ extern ObjectAddress makeOperatorDependencies(HeapTuple tuple, bool isUpdate); extern void OperatorUpd(Oid baseId, Oid commId, Oid negId, bool isDelete); -#endif /* PG_OPERATOR_FN_H */ +#endif /* PG_OPERATOR_FN_H */ diff --git a/src/include/catalog/pg_opfamily.h b/src/include/catalog/pg_opfamily.h index 546527aa8e..0d0ba7c66a 100644 --- a/src/include/catalog/pg_opfamily.h +++ b/src/include/catalog/pg_opfamily.h @@ -187,4 +187,4 @@ DATA(insert OID = 4082 ( 3580 pg_lsn_minmax_ops PGNSP PGUID )); DATA(insert OID = 4104 ( 3580 box_inclusion_ops PGNSP PGUID )); DATA(insert OID = 5000 ( 4000 box_ops PGNSP PGUID )); -#endif /* PG_OPFAMILY_H */ +#endif /* PG_OPFAMILY_H */ diff --git a/src/include/catalog/pg_partitioned_table.h b/src/include/catalog/pg_partitioned_table.h index bdff36a04b..38d64d6511 100644 --- a/src/include/catalog/pg_partitioned_table.h +++ b/src/include/catalog/pg_partitioned_table.h @@ -71,4 +71,4 @@ typedef FormData_pg_partitioned_table *Form_pg_partitioned_table; #define Anum_pg_partitioned_table_partcollation 6 #define Anum_pg_partitioned_table_partexprs 7 -#endif /* PG_PARTITIONED_TABLE_H */ +#endif /* PG_PARTITIONED_TABLE_H */ diff --git a/src/include/catalog/pg_pltemplate.h b/src/include/catalog/pg_pltemplate.h index 6d770fbb3c..fbe71bd0c3 100644 --- a/src/include/catalog/pg_pltemplate.h +++ b/src/include/catalog/pg_pltemplate.h @@ -35,11 +35,11 @@ CATALOG(pg_pltemplate,1136) BKI_SHARED_RELATION BKI_WITHOUT_OIDS bool tmpldbacreate; /* PL is installable by db owner? */ #ifdef CATALOG_VARLEN /* variable-length fields start here */ - text tmplhandler BKI_FORCE_NOT_NULL; /* name of call handler + text tmplhandler BKI_FORCE_NOT_NULL; /* name of call handler * function */ text tmplinline; /* name of anonymous-block handler, or NULL */ text tmplvalidator; /* name of validator function, or NULL */ - text tmpllibrary BKI_FORCE_NOT_NULL; /* path of shared library */ + text tmpllibrary BKI_FORCE_NOT_NULL; /* path of shared library */ aclitem tmplacl[1]; /* access privileges for template */ #endif } FormData_pg_pltemplate; @@ -80,4 +80,4 @@ DATA(insert ( "plpythonu" f f "plpython_call_handler" "plpython_inline_handler" DATA(insert ( "plpython2u" f f "plpython2_call_handler" "plpython2_inline_handler" "plpython2_validator" "$libdir/plpython2" _null_ )); DATA(insert ( "plpython3u" f f "plpython3_call_handler" "plpython3_inline_handler" "plpython3_validator" "$libdir/plpython3" _null_ )); -#endif /* PG_PLTEMPLATE_H */ +#endif /* PG_PLTEMPLATE_H */ diff --git a/src/include/catalog/pg_policy.h b/src/include/catalog/pg_policy.h index 331584f5e0..86000737fa 100644 --- a/src/include/catalog/pg_policy.h +++ b/src/include/catalog/pg_policy.h @@ -52,4 +52,4 @@ typedef FormData_pg_policy *Form_pg_policy; #define Anum_pg_policy_polqual 6 #define Anum_pg_policy_polwithcheck 7 -#endif /* PG_POLICY_H */ +#endif /* PG_POLICY_H */ diff --git a/src/include/catalog/pg_proc.h b/src/include/catalog/pg_proc.h index cafdb8990a..d44c4ecc0b 100644 --- a/src/include/catalog/pg_proc.h +++ b/src/include/catalog/pg_proc.h @@ -63,13 +63,13 @@ CATALOG(pg_proc,1255) BKI_BOOTSTRAP BKI_ROWTYPE_OID(81) BKI_SCHEMA_MACRO oidvector proargtypes; /* parameter types (excludes OUT params) */ #ifdef CATALOG_VARLEN - Oid proallargtypes[1]; /* all param types (NULL if IN only) */ + Oid proallargtypes[1]; /* all param types (NULL if IN only) */ char proargmodes[1]; /* parameter modes (NULL if IN only) */ text proargnames[1]; /* parameter names (NULL if no names) */ - pg_node_tree proargdefaults;/* list of expression trees for argument - * defaults (NULL if none) */ + pg_node_tree proargdefaults; /* list of expression trees for argument + * defaults (NULL if none) */ Oid protrftypes[1]; /* types for which to apply transforms */ - text prosrc BKI_FORCE_NOT_NULL; /* procedure source text */ + text prosrc BKI_FORCE_NOT_NULL; /* procedure source text */ text probin; /* secondary procedure info (can be NULL) */ text proconfig[1]; /* procedure-local GUC settings */ aclitem proacl[1]; /* access permissions */ @@ -5464,8 +5464,10 @@ DATA(insert OID = 6020 ( pg_msgmodule_disable_all PGNSP PGUID 12 1 1 0 0 f f f f DESCR("all processes to ignore overriden log levels"); #endif /* publications */ -DATA(insert OID = 6119 ( pg_get_publication_tables PGNSP PGUID 12 1 1000 0 0 f f t f t t s s 1 0 26 "25" "{25,26}" "{i,o}" "{pubname,relid}" _null_ _null_ pg_get_publication_tables _null_ _null_ _null_ )); +DATA(insert OID = 6119 ( pg_get_publication_tables PGNSP PGUID 12 1 1000 0 0 f f f f t t s s 1 0 26 "25" "{25,26}" "{i,o}" "{pubname,relid}" _null_ _null_ pg_get_publication_tables _null_ _null_ _null_ )); DESCR("get OIDs of tables in a publication"); +DATA(insert OID = 6121 ( pg_relation_is_publishable PGNSP PGUID 12 1 0 0 0 f f f f t f s s 1 0 16 "2205" _null_ _null_ _null_ _null_ _null_ pg_relation_is_publishable _null_ _null_ _null_ )); +DESCR("returns whether a relation can be part of a publication"); /* rls */ DATA(insert OID = 3298 ( row_security_active PGNSP PGUID 12 1 0 0 0 f f f f t f s s 1 0 16 "26" _null_ _null_ _null_ _null_ _null_ row_security_active _null_ _null_ _null_ )); @@ -5490,11 +5492,12 @@ DESCR("pg_controldata recovery state information as a function"); DATA(insert OID = 3444 ( pg_control_init PGNSP PGUID 12 1 0 0 0 f f f f t f v s 0 0 2249 "" "{23,23,23,23,23,23,23,23,23,16,16,23}" "{o,o,o,o,o,o,o,o,o,o,o,o}" "{max_data_alignment,database_block_size,blocks_per_segment,wal_block_size,bytes_per_wal_segment,max_identifier_length,max_index_columns,max_toast_chunk_size,large_object_chunk_size,float4_pass_by_value,float8_pass_by_value,data_page_checksum_version}" _null_ _null_ pg_control_init _null_ _null_ _null_ )); DESCR("pg_controldata init state information as a function"); -DATA(insert OID = 3445 ( pg_import_system_collations PGNSP PGUID 12 100 0 0 0 f f f f t f v r 2 0 2278 "16 4089" _null_ _null_ "{if_not_exists,schema}" _null_ _null_ pg_import_system_collations _null_ _null_ _null_ )); +/* collation management functions */ +DATA(insert OID = 3445 ( pg_import_system_collations PGNSP PGUID 12 100 0 0 0 f f f f t f v r 1 0 23 "4089" _null_ _null_ _null_ _null_ _null_ pg_import_system_collations _null_ _null_ _null_ )); DESCR("import collations from operating system"); DATA(insert OID = 3448 ( pg_collation_actual_version PGNSP PGUID 12 100 0 0 0 f f f f t f v s 1 0 25 "26" _null_ _null_ _null_ _null_ _null_ pg_collation_actual_version _null_ _null_ _null_ )); -DESCR("import collations from operating system"); +DESCR("get actual version of collation from operating system"); /* system management/monitoring related functions */ DATA(insert OID = 3353 ( pg_ls_logdir PGNSP PGUID 12 10 20 0 0 f f f f t t v s 0 0 2249 "" "{25,20,1184}" "{o,o,o}" "{name,size,modification}" _null_ _null_ pg_ls_logdir _null_ _null_ _null_ )); @@ -5510,18 +5513,18 @@ DESCR("list of files in the WAL directory"); * must be labeled volatile to ensure they will not get optimized away, * even if the actual return value is not changeable. */ -#define PROVOLATILE_IMMUTABLE 'i' /* never changes for given input */ -#define PROVOLATILE_STABLE 's' /* does not change within a scan */ -#define PROVOLATILE_VOLATILE 'v' /* can change even within a scan */ +#define PROVOLATILE_IMMUTABLE 'i' /* never changes for given input */ +#define PROVOLATILE_STABLE 's' /* does not change within a scan */ +#define PROVOLATILE_VOLATILE 'v' /* can change even within a scan */ /* * Symbolic values for proparallel column: these indicate whether a function * can be safely be run in a parallel backend, during parallelism but * necessarily in the master, or only in non-parallel mode. */ -#define PROPARALLEL_SAFE 's' /* can run in worker or master */ -#define PROPARALLEL_RESTRICTED 'r' /* can run in parallel master only */ -#define PROPARALLEL_UNSAFE 'u' /* banned while in parallel mode */ +#define PROPARALLEL_SAFE 's' /* can run in worker or master */ +#define PROPARALLEL_RESTRICTED 'r' /* can run in parallel master only */ +#define PROPARALLEL_UNSAFE 'u' /* banned while in parallel mode */ /* * Symbolic values for proargmodes column. Note that these must agree with @@ -5534,4 +5537,4 @@ DESCR("list of files in the WAL directory"); #define PROARGMODE_VARIADIC 'v' #define PROARGMODE_TABLE 't' -#endif /* PG_PROC_H */ +#endif /* PG_PROC_H */ diff --git a/src/include/catalog/pg_proc_fn.h b/src/include/catalog/pg_proc_fn.h index 993278a91a..2c85f5d267 100644 --- a/src/include/catalog/pg_proc_fn.h +++ b/src/include/catalog/pg_proc_fn.h @@ -48,4 +48,4 @@ extern bool function_parse_error_transpose(const char *prosrc); extern List *oid_array_to_list(Datum datum); -#endif /* PG_PROC_FN_H */ +#endif /* PG_PROC_FN_H */ diff --git a/src/include/catalog/pg_publication.h b/src/include/catalog/pg_publication.h index c2086c1f42..aa148960cd 100644 --- a/src/include/catalog/pg_publication.h +++ b/src/include/catalog/pg_publication.h @@ -101,4 +101,4 @@ extern char *get_publication_name(Oid pubid); extern Datum pg_get_publication_tables(PG_FUNCTION_ARGS); -#endif /* PG_PUBLICATION_H */ +#endif /* PG_PUBLICATION_H */ diff --git a/src/include/catalog/pg_publication_rel.h b/src/include/catalog/pg_publication_rel.h index f889b6f4db..3729e5abdc 100644 --- a/src/include/catalog/pg_publication_rel.h +++ b/src/include/catalog/pg_publication_rel.h @@ -49,4 +49,4 @@ typedef FormData_pg_publication_rel *Form_pg_publication_rel; #define Anum_pg_publication_rel_prpubid 1 #define Anum_pg_publication_rel_prrelid 2 -#endif /* PG_PUBLICATION_REL_H */ +#endif /* PG_PUBLICATION_REL_H */ diff --git a/src/include/catalog/pg_range.h b/src/include/catalog/pg_range.h index 4ed57fe2e9..f12e82b2f2 100644 --- a/src/include/catalog/pg_range.h +++ b/src/include/catalog/pg_range.h @@ -82,4 +82,4 @@ extern void RangeCreate(Oid rangeTypeOid, Oid rangeSubType, Oid rangeCollation, RegProcedure rangeSubDiff); extern void RangeDelete(Oid rangeTypeOid); -#endif /* PG_RANGE_H */ +#endif /* PG_RANGE_H */ diff --git a/src/include/catalog/pg_replication_origin.h b/src/include/catalog/pg_replication_origin.h index c22831f517..24c8a8430c 100644 --- a/src/include/catalog/pg_replication_origin.h +++ b/src/include/catalog/pg_replication_origin.h @@ -46,7 +46,7 @@ CATALOG(pg_replication_origin,6000) BKI_SHARED_RELATION BKI_WITHOUT_OIDS */ /* external, free-format, name */ - text roname BKI_FORCE_NOT_NULL; + text roname BKI_FORCE_NOT_NULL; #ifdef CATALOG_VARLEN /* further variable-length fields */ #endif @@ -67,4 +67,4 @@ typedef FormData_pg_replication_origin *Form_pg_replication_origin; * ---------------- */ -#endif /* PG_REPLICATION_ORIGIN_H */ +#endif /* PG_REPLICATION_ORIGIN_H */ diff --git a/src/include/catalog/pg_rewrite.h b/src/include/catalog/pg_rewrite.h index 425a336755..48b9333a9d 100644 --- a/src/include/catalog/pg_rewrite.h +++ b/src/include/catalog/pg_rewrite.h @@ -65,4 +65,4 @@ typedef FormData_pg_rewrite *Form_pg_rewrite; #define Anum_pg_rewrite_ev_qual 6 #define Anum_pg_rewrite_ev_action 7 -#endif /* PG_REWRITE_H */ +#endif /* PG_REWRITE_H */ diff --git a/src/include/catalog/pg_seclabel.h b/src/include/catalog/pg_seclabel.h index 01e14e77c0..3db9612fc3 100644 --- a/src/include/catalog/pg_seclabel.h +++ b/src/include/catalog/pg_seclabel.h @@ -27,8 +27,8 @@ CATALOG(pg_seclabel,3596) BKI_WITHOUT_OIDS int32 objsubid; /* column number, or 0 if not used */ #ifdef CATALOG_VARLEN /* variable-length fields start here */ - text provider BKI_FORCE_NOT_NULL; /* name of label provider */ - text label BKI_FORCE_NOT_NULL; /* security label of the object */ + text provider BKI_FORCE_NOT_NULL; /* name of label provider */ + text label BKI_FORCE_NOT_NULL; /* security label of the object */ #endif } FormData_pg_seclabel; @@ -43,4 +43,4 @@ CATALOG(pg_seclabel,3596) BKI_WITHOUT_OIDS #define Anum_pg_seclabel_provider 4 #define Anum_pg_seclabel_label 5 -#endif /* PG_SECLABEL_H */ +#endif /* PG_SECLABEL_H */ diff --git a/src/include/catalog/pg_sequence.h b/src/include/catalog/pg_sequence.h index 26d2993674..8ae6b7143d 100644 --- a/src/include/catalog/pg_sequence.h +++ b/src/include/catalog/pg_sequence.h @@ -29,4 +29,4 @@ typedef FormData_pg_sequence *Form_pg_sequence; #define Anum_pg_sequence_seqcache 7 #define Anum_pg_sequence_seqcycle 8 -#endif /* PG_SEQUENCE_H */ +#endif /* PG_SEQUENCE_H */ diff --git a/src/include/catalog/pg_shdepend.h b/src/include/catalog/pg_shdepend.h index ae1aa4f952..51b6588d3e 100644 --- a/src/include/catalog/pg_shdepend.h +++ b/src/include/catalog/pg_shdepend.h @@ -87,4 +87,4 @@ typedef FormData_pg_shdepend *Form_pg_shdepend; * are explicitly stored in pg_shdepend. */ -#endif /* PG_SHDEPEND_H */ +#endif /* PG_SHDEPEND_H */ diff --git a/src/include/catalog/pg_shdescription.h b/src/include/catalog/pg_shdescription.h index 21086447fa..154c48b584 100644 --- a/src/include/catalog/pg_shdescription.h +++ b/src/include/catalog/pg_shdescription.h @@ -44,7 +44,7 @@ CATALOG(pg_shdescription,2396) BKI_SHARED_RELATION BKI_WITHOUT_OIDS Oid classoid; /* OID of table containing object */ #ifdef CATALOG_VARLEN /* variable-length fields start here */ - text description BKI_FORCE_NOT_NULL; /* description of object */ + text description BKI_FORCE_NOT_NULL; /* description of object */ #endif } FormData_pg_shdescription; @@ -53,7 +53,7 @@ CATALOG(pg_shdescription,2396) BKI_SHARED_RELATION BKI_WITHOUT_OIDS * the format of pg_shdescription relation. * ---------------- */ -typedef FormData_pg_shdescription *Form_pg_shdescription; +typedef FormData_pg_shdescription * Form_pg_shdescription; /* ---------------- * compiler constants for pg_shdescription @@ -75,4 +75,4 @@ typedef FormData_pg_shdescription *Form_pg_shdescription; * by genbki.pl and loaded during initdb. */ -#endif /* PG_SHDESCRIPTION_H */ +#endif /* PG_SHDESCRIPTION_H */ diff --git a/src/include/catalog/pg_shseclabel.h b/src/include/catalog/pg_shseclabel.h index a88f65c169..f8a906bb12 100644 --- a/src/include/catalog/pg_shseclabel.h +++ b/src/include/catalog/pg_shseclabel.h @@ -27,12 +27,12 @@ CATALOG(pg_shseclabel,3592) BKI_SHARED_RELATION BKI_ROWTYPE_OID(4066) BKI_WITHOU Oid classoid; /* OID of table containing the shared object */ #ifdef CATALOG_VARLEN /* variable-length fields start here */ - text provider BKI_FORCE_NOT_NULL; /* name of label provider */ - text label BKI_FORCE_NOT_NULL; /* security label of the object */ + text provider BKI_FORCE_NOT_NULL; /* name of label provider */ + text label BKI_FORCE_NOT_NULL; /* security label of the object */ #endif } FormData_pg_shseclabel; -typedef FormData_pg_shseclabel *Form_pg_shseclabel; +typedef FormData_pg_shseclabel * Form_pg_shseclabel; /* ---------------- * compiler constants for pg_shseclabel @@ -44,4 +44,4 @@ typedef FormData_pg_shseclabel *Form_pg_shseclabel; #define Anum_pg_shseclabel_provider 3 #define Anum_pg_shseclabel_label 4 -#endif /* PG_SHSECLABEL_H */ +#endif /* PG_SHSECLABEL_H */ diff --git a/src/include/catalog/pg_statistic.h b/src/include/catalog/pg_statistic.h index 3576419a2f..3713a56bbd 100644 --- a/src/include/catalog/pg_statistic.h +++ b/src/include/catalog/pg_statistic.h @@ -291,4 +291,4 @@ typedef FormData_pg_statistic *Form_pg_statistic; */ #define STATISTIC_KIND_BOUNDS_HISTOGRAM 7 -#endif /* PG_STATISTIC_H */ +#endif /* PG_STATISTIC_H */ diff --git a/src/include/catalog/pg_statistic_ext.h b/src/include/catalog/pg_statistic_ext.h index d302b7fc01..78138026db 100644 --- a/src/include/catalog/pg_statistic_ext.h +++ b/src/include/catalog/pg_statistic_ext.h @@ -77,4 +77,4 @@ typedef FormData_pg_statistic_ext *Form_pg_statistic_ext; #define STATS_EXT_NDISTINCT 'd' #define STATS_EXT_DEPENDENCIES 'f' -#endif /* PG_STATISTIC_EXT_H */ +#endif /* PG_STATISTIC_EXT_H */ diff --git a/src/include/catalog/pg_subscription.h b/src/include/catalog/pg_subscription.h index b2cebd4a4b..274ff6bc42 100644 --- a/src/include/catalog/pg_subscription.h +++ b/src/include/catalog/pg_subscription.h @@ -42,13 +42,13 @@ CATALOG(pg_subscription,6100) BKI_SHARED_RELATION BKI_ROWTYPE_OID(6101) BKI_SCHE #ifdef CATALOG_VARLEN /* variable-length fields start here */ /* Connection string to the publisher */ - text subconninfo BKI_FORCE_NOT_NULL; + text subconninfo BKI_FORCE_NOT_NULL; /* Slot name on publisher */ NameData subslotname; /* Synchronous commit setting for worker */ - text subsynccommit BKI_FORCE_NOT_NULL; + text subsynccommit BKI_FORCE_NOT_NULL; /* List of publications subscribed to */ text subpublications[1] BKI_FORCE_NOT_NULL; @@ -93,4 +93,4 @@ extern char *get_subscription_name(Oid subid); extern int CountDBSubscriptions(Oid dbid); -#endif /* PG_SUBSCRIPTION_H */ +#endif /* PG_SUBSCRIPTION_H */ diff --git a/src/include/catalog/pg_subscription_rel.h b/src/include/catalog/pg_subscription_rel.h index f5f6191676..991ca9d552 100644 --- a/src/include/catalog/pg_subscription_rel.h +++ b/src/include/catalog/pg_subscription_rel.h @@ -51,17 +51,17 @@ typedef FormData_pg_subscription_rel *Form_pg_subscription_rel; * substate constants * ---------------- */ -#define SUBREL_STATE_INIT 'i' /* initializing (sublsn NULL) */ -#define SUBREL_STATE_DATASYNC 'd' /* data is being synchronized (sublsn - * NULL) */ -#define SUBREL_STATE_SYNCDONE 's' /* synchronization finished in front - * of apply (sublsn set) */ -#define SUBREL_STATE_READY 'r' /* ready (sublsn set) */ +#define SUBREL_STATE_INIT 'i' /* initializing (sublsn NULL) */ +#define SUBREL_STATE_DATASYNC 'd' /* data is being synchronized (sublsn + * NULL) */ +#define SUBREL_STATE_SYNCDONE 's' /* synchronization finished in front of + * apply (sublsn set) */ +#define SUBREL_STATE_READY 'r' /* ready (sublsn set) */ /* These are never stored in the catalog, we only use them for IPC. */ #define SUBREL_STATE_UNKNOWN '\0' /* unknown state */ -#define SUBREL_STATE_SYNCWAIT 'w' /* waiting for sync */ -#define SUBREL_STATE_CATCHUP 'c' /* catching up with apply */ +#define SUBREL_STATE_SYNCWAIT 'w' /* waiting for sync */ +#define SUBREL_STATE_CATCHUP 'c' /* catching up with apply */ typedef struct SubscriptionRelState { @@ -79,4 +79,4 @@ extern void RemoveSubscriptionRel(Oid subid, Oid relid); extern List *GetSubscriptionRelations(Oid subid); extern List *GetSubscriptionNotReadyRelations(Oid subid); -#endif /* PG_SUBSCRIPTION_REL_H */ +#endif /* PG_SUBSCRIPTION_REL_H */ diff --git a/src/include/catalog/pg_tablespace.h b/src/include/catalog/pg_tablespace.h index d9ea4b7d63..b759d5cea4 100644 --- a/src/include/catalog/pg_tablespace.h +++ b/src/include/catalog/pg_tablespace.h @@ -63,4 +63,4 @@ DATA(insert OID = 1664 ( pg_global PGUID _null_ _null_ )); #define DEFAULTTABLESPACE_OID 1663 #define GLOBALTABLESPACE_OID 1664 -#endif /* PG_TABLESPACE_H */ +#endif /* PG_TABLESPACE_H */ diff --git a/src/include/catalog/pg_transform.h b/src/include/catalog/pg_transform.h index 3415db3bd6..8b1610bb83 100644 --- a/src/include/catalog/pg_transform.h +++ b/src/include/catalog/pg_transform.h @@ -44,4 +44,4 @@ typedef FormData_pg_transform *Form_pg_transform; #define Anum_pg_transform_trffromsql 3 #define Anum_pg_transform_trftosql 4 -#endif /* PG_TRANSFORM_H */ +#endif /* PG_TRANSFORM_H */ diff --git a/src/include/catalog/pg_trigger.h b/src/include/catalog/pg_trigger.h index 547332fe65..f413caf34f 100644 --- a/src/include/catalog/pg_trigger.h +++ b/src/include/catalog/pg_trigger.h @@ -57,7 +57,7 @@ CATALOG(pg_trigger,2620) int2vector tgattr; /* column numbers, if trigger is on columns */ #ifdef CATALOG_VARLEN - bytea tgargs BKI_FORCE_NOT_NULL; /* first\000second\000tgnargs\000 */ + bytea tgargs BKI_FORCE_NOT_NULL; /* first\000second\000tgnargs\000 */ pg_node_tree tgqual; /* WHEN expression, or NULL if none */ NameData tgoldtable; /* old transition table, or NULL if none */ NameData tgnewtable; /* new transition table, or NULL if none */ @@ -153,4 +153,4 @@ typedef FormData_pg_trigger *Form_pg_trigger; #define TRIGGER_USES_TRANSITION_TABLE(namepointer) \ ((namepointer) != (char *) NULL) -#endif /* PG_TRIGGER_H */ +#endif /* PG_TRIGGER_H */ diff --git a/src/include/catalog/pg_ts_config.h b/src/include/catalog/pg_ts_config.h index b61cf857d9..0ba79a596f 100644 --- a/src/include/catalog/pg_ts_config.h +++ b/src/include/catalog/pg_ts_config.h @@ -57,4 +57,4 @@ typedef FormData_pg_ts_config *Form_pg_ts_config; DATA(insert OID = 3748 ( "simple" PGNSP PGUID 3722 )); DESCR("simple configuration"); -#endif /* PG_TS_CONFIG_H */ +#endif /* PG_TS_CONFIG_H */ diff --git a/src/include/catalog/pg_ts_config_map.h b/src/include/catalog/pg_ts_config_map.h index fc9467fd9c..3df05195be 100644 --- a/src/include/catalog/pg_ts_config_map.h +++ b/src/include/catalog/pg_ts_config_map.h @@ -75,4 +75,4 @@ DATA(insert ( 3748 20 1 3765 )); DATA(insert ( 3748 21 1 3765 )); DATA(insert ( 3748 22 1 3765 )); -#endif /* PG_TS_CONFIG_MAP_H */ +#endif /* PG_TS_CONFIG_MAP_H */ diff --git a/src/include/catalog/pg_ts_dict.h b/src/include/catalog/pg_ts_dict.h index 28b7bb7c0d..634ea703e3 100644 --- a/src/include/catalog/pg_ts_dict.h +++ b/src/include/catalog/pg_ts_dict.h @@ -63,4 +63,4 @@ typedef FormData_pg_ts_dict *Form_pg_ts_dict; DATA(insert OID = 3765 ( "simple" PGNSP PGUID 3727 _null_)); DESCR("simple dictionary: just lower case and check for stopword"); -#endif /* PG_TS_DICT_H */ +#endif /* PG_TS_DICT_H */ diff --git a/src/include/catalog/pg_ts_parser.h b/src/include/catalog/pg_ts_parser.h index cfb87b4d56..96e09bdcd8 100644 --- a/src/include/catalog/pg_ts_parser.h +++ b/src/include/catalog/pg_ts_parser.h @@ -64,4 +64,4 @@ typedef FormData_pg_ts_parser *Form_pg_ts_parser; DATA(insert OID = 3722 ( "default" PGNSP prsd_start prsd_nexttoken prsd_end prsd_headline prsd_lextype )); DESCR("default word parser"); -#endif /* PG_TS_PARSER_H */ +#endif /* PG_TS_PARSER_H */ diff --git a/src/include/catalog/pg_ts_template.h b/src/include/catalog/pg_ts_template.h index 5fc6eea243..dc0148c68b 100644 --- a/src/include/catalog/pg_ts_template.h +++ b/src/include/catalog/pg_ts_template.h @@ -64,4 +64,4 @@ DESCR("ispell dictionary"); DATA(insert OID = 3742 ( "thesaurus" PGNSP thesaurus_init thesaurus_lexize )); DESCR("thesaurus dictionary: phrase by phrase substitution"); -#endif /* PG_TS_TEMPLATE_H */ +#endif /* PG_TS_TEMPLATE_H */ diff --git a/src/include/catalog/pg_type.h b/src/include/catalog/pg_type.h index 8dfbc8a15f..e4a81a113d 100644 --- a/src/include/catalog/pg_type.h +++ b/src/include/catalog/pg_type.h @@ -732,14 +732,14 @@ DATA(insert OID = 3831 ( anyrange PGNSP PGUID -1 f p P f t \054 0 0 0 anyrange #define TYPCATEGORY_DATETIME 'D' #define TYPCATEGORY_ENUM 'E' #define TYPCATEGORY_GEOMETRIC 'G' -#define TYPCATEGORY_NETWORK 'I' /* think INET */ +#define TYPCATEGORY_NETWORK 'I' /* think INET */ #define TYPCATEGORY_NUMERIC 'N' #define TYPCATEGORY_PSEUDOTYPE 'P' #define TYPCATEGORY_RANGE 'R' #define TYPCATEGORY_STRING 'S' #define TYPCATEGORY_TIMESPAN 'T' #define TYPCATEGORY_USER 'U' -#define TYPCATEGORY_BITSTRING 'V' /* er ... "varbit"? */ +#define TYPCATEGORY_BITSTRING 'V' /* er ... "varbit"? */ #define TYPCATEGORY_UNKNOWN 'X' /* Is a type OID a polymorphic pseudotype? (Beware of multiple evaluation) */ @@ -750,4 +750,4 @@ DATA(insert OID = 3831 ( anyrange PGNSP PGUID -1 f p P f t \054 0 0 0 anyrange (typid) == ANYENUMOID || \ (typid) == ANYRANGEOID) -#endif /* PG_TYPE_H */ +#endif /* PG_TYPE_H */ diff --git a/src/include/catalog/pg_type_fn.h b/src/include/catalog/pg_type_fn.h index 01f095612d..b570d3588f 100644 --- a/src/include/catalog/pg_type_fn.h +++ b/src/include/catalog/pg_type_fn.h @@ -81,4 +81,4 @@ extern char *makeArrayTypeName(const char *typeName, Oid typeNamespace); extern bool moveArrayTypeName(Oid typeOid, const char *typeName, Oid typeNamespace); -#endif /* PG_TYPE_FN_H */ +#endif /* PG_TYPE_FN_H */ diff --git a/src/include/catalog/pg_user_mapping.h b/src/include/catalog/pg_user_mapping.h index 1ebf4611df..f08e6a72ed 100644 --- a/src/include/catalog/pg_user_mapping.h +++ b/src/include/catalog/pg_user_mapping.h @@ -54,4 +54,4 @@ typedef FormData_pg_user_mapping *Form_pg_user_mapping; #define Anum_pg_user_mapping_umserver 2 #define Anum_pg_user_mapping_umoptions 3 -#endif /* PG_USER_MAPPING_H */ +#endif /* PG_USER_MAPPING_H */ diff --git a/src/include/catalog/storage.h b/src/include/catalog/storage.h index fea96deba3..a3a97db929 100644 --- a/src/include/catalog/storage.h +++ b/src/include/catalog/storage.h @@ -33,4 +33,4 @@ extern void AtSubCommit_smgr(void); extern void AtSubAbort_smgr(void); extern void PostPrepare_smgr(void); -#endif /* STORAGE_H */ +#endif /* STORAGE_H */ diff --git a/src/include/catalog/storage_xlog.h b/src/include/catalog/storage_xlog.h index fcdd0233b1..4c08005228 100644 --- a/src/include/catalog/storage_xlog.h +++ b/src/include/catalog/storage_xlog.h @@ -56,4 +56,4 @@ extern void smgr_redo(XLogReaderState *record); extern void smgr_desc(StringInfo buf, XLogReaderState *record); extern const char *smgr_identify(uint8 info); -#endif /* STORAGE_XLOG_H */ +#endif /* STORAGE_XLOG_H */ diff --git a/src/include/catalog/toasting.h b/src/include/catalog/toasting.h index 00d0a8326f..f82a799572 100644 --- a/src/include/catalog/toasting.h +++ b/src/include/catalog/toasting.h @@ -67,4 +67,4 @@ DECLARE_TOAST(pg_shseclabel, 4060, 4061); #define PgShseclabelToastTable 4060 #define PgShseclabelToastIndex 4061 -#endif /* TOASTING_H */ +#endif /* TOASTING_H */ diff --git a/src/include/commands/alter.h b/src/include/commands/alter.h index b7aa86cb57..4365357ab8 100644 --- a/src/include/commands/alter.h +++ b/src/include/commands/alter.h @@ -32,4 +32,4 @@ extern ObjectAddress ExecAlterOwnerStmt(AlterOwnerStmt *stmt); extern void AlterObjectOwner_internal(Relation catalog, Oid objectId, Oid new_ownerId); -#endif /* ALTER_H */ +#endif /* ALTER_H */ diff --git a/src/include/commands/async.h b/src/include/commands/async.h index b7842d1a0f..939711d8d9 100644 --- a/src/include/commands/async.h +++ b/src/include/commands/async.h @@ -54,4 +54,4 @@ extern void HandleNotifyInterrupt(void); /* process interrupts */ extern void ProcessNotifyInterrupt(void); -#endif /* ASYNC_H */ +#endif /* ASYNC_H */ diff --git a/src/include/commands/cluster.h b/src/include/commands/cluster.h index 7c9d4746d9..7bade9fad2 100644 --- a/src/include/commands/cluster.h +++ b/src/include/commands/cluster.h @@ -36,4 +36,4 @@ extern void finish_heap_swap(Oid OIDOldHeap, Oid OIDNewHeap, MultiXactId minMulti, char newrelpersistence); -#endif /* CLUSTER_H */ +#endif /* CLUSTER_H */ diff --git a/src/include/commands/collationcmds.h b/src/include/commands/collationcmds.h index df5623ccb6..30e847432e 100644 --- a/src/include/commands/collationcmds.h +++ b/src/include/commands/collationcmds.h @@ -22,4 +22,4 @@ extern ObjectAddress DefineCollation(ParseState *pstate, List *names, List *para extern void IsThereCollationInNamespace(const char *collname, Oid nspOid); extern ObjectAddress AlterCollation(AlterCollationStmt *stmt); -#endif /* COLLATIONCMDS_H */ +#endif /* COLLATIONCMDS_H */ diff --git a/src/include/commands/comment.h b/src/include/commands/comment.h index 684ea8b697..85bd801513 100644 --- a/src/include/commands/comment.h +++ b/src/include/commands/comment.h @@ -42,4 +42,4 @@ extern void CreateSharedComments(Oid oid, Oid classoid, char *comment); extern char *GetComment(Oid oid, Oid classoid, int32 subid); -#endif /* COMMENT_H */ +#endif /* COMMENT_H */ diff --git a/src/include/commands/conversioncmds.h b/src/include/commands/conversioncmds.h index 20d7f0e9b1..7054505794 100644 --- a/src/include/commands/conversioncmds.h +++ b/src/include/commands/conversioncmds.h @@ -20,4 +20,4 @@ extern ObjectAddress CreateConversionCommand(CreateConversionStmt *parsetree); -#endif /* CONVERSIONCMDS_H */ +#endif /* CONVERSIONCMDS_H */ diff --git a/src/include/commands/copy.h b/src/include/commands/copy.h index f081f2219f..8b2971d287 100644 --- a/src/include/commands/copy.h +++ b/src/include/commands/copy.h @@ -41,4 +41,4 @@ extern uint64 CopyFrom(CopyState cstate); extern DestReceiver *CreateCopyDestReceiver(void); -#endif /* COPY_H */ +#endif /* COPY_H */ diff --git a/src/include/commands/createas.h b/src/include/commands/createas.h index c3c43f6b36..aaf4fac97b 100644 --- a/src/include/commands/createas.h +++ b/src/include/commands/createas.h @@ -22,10 +22,10 @@ extern ObjectAddress ExecCreateTableAs(CreateTableAsStmt *stmt, const char *queryString, - ParamListInfo params, QueryEnvironment *queryEnv, char *completionTag); + ParamListInfo params, QueryEnvironment *queryEnv, char *completionTag); extern int GetIntoRelEFlags(IntoClause *intoClause); extern DestReceiver *CreateIntoRelDestReceiver(IntoClause *intoClause); -#endif /* CREATEAS_H */ +#endif /* CREATEAS_H */ diff --git a/src/include/commands/dbcommands.h b/src/include/commands/dbcommands.h index 5a74a02a5d..91186654d0 100644 --- a/src/include/commands/dbcommands.h +++ b/src/include/commands/dbcommands.h @@ -35,4 +35,4 @@ extern void check_encoding_locale_matches(int encoding, const char *collate, con extern bool IsSetTableSpace(AlterDatabaseStmt *stmt); #endif -#endif /* DBCOMMANDS_H */ +#endif /* DBCOMMANDS_H */ diff --git a/src/include/commands/dbcommands_xlog.h b/src/include/commands/dbcommands_xlog.h index 6583d0d5bd..63b1a6470c 100644 --- a/src/include/commands/dbcommands_xlog.h +++ b/src/include/commands/dbcommands_xlog.h @@ -41,4 +41,4 @@ extern void dbase_redo(XLogReaderState *rptr); extern void dbase_desc(StringInfo buf, XLogReaderState *rptr); extern const char *dbase_identify(uint8 info); -#endif /* DBCOMMANDS_XLOG_H */ +#endif /* DBCOMMANDS_XLOG_H */ diff --git a/src/include/commands/defrem.h b/src/include/commands/defrem.h index 5dd14b43d3..f7bb4a54f7 100644 --- a/src/include/commands/defrem.h +++ b/src/include/commands/defrem.h @@ -164,4 +164,4 @@ extern TypeName *defGetTypeName(DefElem *def); extern int defGetTypeLength(DefElem *def); extern List *defGetStringList(DefElem *def); -#endif /* DEFREM_H */ +#endif /* DEFREM_H */ diff --git a/src/include/commands/discard.h b/src/include/commands/discard.h index b960cab51f..8ea0b30ddf 100644 --- a/src/include/commands/discard.h +++ b/src/include/commands/discard.h @@ -17,4 +17,4 @@ extern void DiscardCommand(DiscardStmt *stmt, bool isTopLevel); -#endif /* DISCARD_H */ +#endif /* DISCARD_H */ diff --git a/src/include/commands/event_trigger.h b/src/include/commands/event_trigger.h index 0017bd0cd4..2ce528272c 100644 --- a/src/include/commands/event_trigger.h +++ b/src/include/commands/event_trigger.h @@ -86,4 +86,4 @@ extern void EventTriggerCollectAlterTSConfig(AlterTSConfigurationStmt *stmt, Oid cfgId, Oid *dictIds, int ndicts); extern void EventTriggerCollectAlterDefPrivs(AlterDefaultPrivilegesStmt *stmt); -#endif /* EVENT_TRIGGER_H */ +#endif /* EVENT_TRIGGER_H */ diff --git a/src/include/commands/explain.h b/src/include/commands/explain.h index 5882aff24d..c4dfdc3d6b 100644 --- a/src/include/commands/explain.h +++ b/src/include/commands/explain.h @@ -48,16 +48,16 @@ typedef struct ExplainState List *rtable; /* range table */ List *rtable_names; /* alias names for RTEs */ List *deparse_cxt; /* context list for deparsing expressions */ - Bitmapset *printed_subplans; /* ids of SubPlans we've printed */ + Bitmapset *printed_subplans; /* ids of SubPlans we've printed */ } ExplainState; /* Hook for plugins to get control in ExplainOneQuery() */ typedef void (*ExplainOneQuery_hook_type) (Query *query, - int cursorOptions, - IntoClause *into, - ExplainState *es, - const char *queryString, - ParamListInfo params); + int cursorOptions, + IntoClause *into, + ExplainState *es, + const char *queryString, + ParamListInfo params); extern PGDLLIMPORT ExplainOneQuery_hook_type ExplainOneQuery_hook; /* Hook for plugins to get control in explain_get_index_name() */ @@ -66,7 +66,7 @@ extern PGDLLIMPORT explain_get_index_name_hook_type explain_get_index_name_hook; extern void ExplainQuery(ParseState *pstate, ExplainStmt *stmt, const char *queryString, - ParamListInfo params, QueryEnvironment *queryEnv, DestReceiver *dest); + ParamListInfo params, QueryEnvironment *queryEnv, DestReceiver *dest); extern ExplainState *NewExplainState(void); @@ -105,4 +105,4 @@ extern void ExplainPropertyFloat(const char *qlabel, double value, int ndigits, extern void ExplainPropertyBool(const char *qlabel, bool value, ExplainState *es); -#endif /* EXPLAIN_H */ +#endif /* EXPLAIN_H */ diff --git a/src/include/commands/extension.h b/src/include/commands/extension.h index 7f027d9dc7..73bba3c784 100644 --- a/src/include/commands/extension.h +++ b/src/include/commands/extension.h @@ -53,4 +53,4 @@ extern ObjectAddress AlterExtensionNamespace(const char *extensionName, const ch extern void AlterExtensionOwner_oid(Oid extensionOid, Oid newOwnerId); -#endif /* EXTENSION_H */ +#endif /* EXTENSION_H */ diff --git a/src/include/commands/lockcmds.h b/src/include/commands/lockcmds.h index 45ed96d4d1..cdb5c62a52 100644 --- a/src/include/commands/lockcmds.h +++ b/src/include/commands/lockcmds.h @@ -21,4 +21,4 @@ */ extern void LockTableCommand(LockStmt *lockstmt); -#endif /* LOCKCMDS_H */ +#endif /* LOCKCMDS_H */ diff --git a/src/include/commands/matview.h b/src/include/commands/matview.h index 129fb92f59..3feb137ef4 100644 --- a/src/include/commands/matview.h +++ b/src/include/commands/matview.h @@ -30,4 +30,4 @@ extern DestReceiver *CreateTransientRelDestReceiver(Oid oid); extern bool MatViewIncrementalMaintenanceIsEnabled(void); -#endif /* MATVIEW_H */ +#endif /* MATVIEW_H */ diff --git a/src/include/commands/policy.h b/src/include/commands/policy.h index cff93a6cb0..d6a920ccef 100644 --- a/src/include/commands/policy.h +++ b/src/include/commands/policy.h @@ -35,4 +35,4 @@ extern ObjectAddress rename_policy(RenameStmt *stmt); extern bool relation_has_policies(Relation rel); -#endif /* POLICY_H */ +#endif /* POLICY_H */ diff --git a/src/include/commands/portalcmds.h b/src/include/commands/portalcmds.h index 8f0e6c48f4..488ce60cd6 100644 --- a/src/include/commands/portalcmds.h +++ b/src/include/commands/portalcmds.h @@ -30,4 +30,4 @@ extern void PortalCleanup(Portal portal); extern void PersistHoldablePortal(Portal portal); -#endif /* PORTALCMDS_H */ +#endif /* PORTALCMDS_H */ diff --git a/src/include/commands/prepare.h b/src/include/commands/prepare.h index 147f22b870..0d84d5aeba 100644 --- a/src/include/commands/prepare.h +++ b/src/include/commands/prepare.h @@ -28,7 +28,7 @@ typedef struct { /* dynahash.c requires key to be first field */ char stmt_name[NAMEDATALEN]; - CachedPlanSource *plansource; /* the actual cached plan */ + CachedPlanSource *plansource; /* the actual cached plan */ bool from_sql; /* prepared via SQL, not FE/BE protocol? */ #ifdef XCP bool use_resowner; /* does it use resowner for tracking? */ @@ -79,4 +79,4 @@ extern int SetRemoteStatementName(Plan *plan, const char *stmt_name, int num_par Oid *param_types, int n); #endif -#endif /* PREPARE_H */ +#endif /* PREPARE_H */ diff --git a/src/include/commands/proclang.h b/src/include/commands/proclang.h index f056978805..9a4bc75d12 100644 --- a/src/include/commands/proclang.h +++ b/src/include/commands/proclang.h @@ -20,4 +20,4 @@ extern void DropProceduralLanguageById(Oid langOid); extern bool PLTemplateExists(const char *languageName); extern Oid get_language_oid(const char *langname, bool missing_ok); -#endif /* PROCLANG_H */ +#endif /* PROCLANG_H */ diff --git a/src/include/commands/publicationcmds.h b/src/include/commands/publicationcmds.h index 7f12ff0a1b..a2e0f4a21e 100644 --- a/src/include/commands/publicationcmds.h +++ b/src/include/commands/publicationcmds.h @@ -26,4 +26,4 @@ extern void RemovePublicationRelById(Oid proid); extern ObjectAddress AlterPublicationOwner(const char *name, Oid newOwnerId); extern void AlterPublicationOwner_oid(Oid pubid, Oid newOwnerId); -#endif /* PUBLICATIONCMDS_H */ +#endif /* PUBLICATIONCMDS_H */ diff --git a/src/include/commands/schemacmds.h b/src/include/commands/schemacmds.h index 7079bfbf5a..25771bfe29 100644 --- a/src/include/commands/schemacmds.h +++ b/src/include/commands/schemacmds.h @@ -29,4 +29,4 @@ extern ObjectAddress RenameSchema(const char *oldname, const char *newname); extern ObjectAddress AlterSchemaOwner(const char *name, Oid newOwnerId); extern void AlterSchemaOwner_oid(Oid schemaOid, Oid newOwnerId); -#endif /* SCHEMACMDS_H */ +#endif /* SCHEMACMDS_H */ diff --git a/src/include/commands/seclabel.h b/src/include/commands/seclabel.h index d317f39485..a97c3293b2 100644 --- a/src/include/commands/seclabel.h +++ b/src/include/commands/seclabel.h @@ -27,8 +27,8 @@ extern void DeleteSharedSecurityLabel(Oid objectId, Oid classId); extern ObjectAddress ExecSecLabelStmt(SecLabelStmt *stmt); typedef void (*check_object_relabel_type) (const ObjectAddress *object, - const char *seclabel); + const char *seclabel); extern void register_label_provider(const char *provider, check_object_relabel_type hook); -#endif /* SECLABEL_H */ +#endif /* SECLABEL_H */ diff --git a/src/include/commands/sequence.h b/src/include/commands/sequence.h index 0e9533cc2d..7d9cfe80e7 100644 --- a/src/include/commands/sequence.h +++ b/src/include/commands/sequence.h @@ -93,4 +93,4 @@ extern bool IsTempSequence(Oid relid); extern char *GetGlobalSeqName(Relation rel, const char *new_seqname, const char *new_schemaname); #endif -#endif /* SEQUENCE_H */ +#endif /* SEQUENCE_H */ diff --git a/src/include/commands/subscriptioncmds.h b/src/include/commands/subscriptioncmds.h index 1e4428e617..3d92a682a1 100644 --- a/src/include/commands/subscriptioncmds.h +++ b/src/include/commands/subscriptioncmds.h @@ -26,4 +26,4 @@ extern void DropSubscription(DropSubscriptionStmt *stmt, bool isTopLevel); extern ObjectAddress AlterSubscriptionOwner(const char *name, Oid newOwnerId); extern void AlterSubscriptionOwner_oid(Oid subid, Oid newOwnerId); -#endif /* SUBSCRIPTIONCMDS_H */ +#endif /* SUBSCRIPTIONCMDS_H */ diff --git a/src/include/commands/tablecmds.h b/src/include/commands/tablecmds.h index a27fdfbfce..bba254a011 100644 --- a/src/include/commands/tablecmds.h +++ b/src/include/commands/tablecmds.h @@ -96,4 +96,4 @@ extern void RangeVarCallbackOwnsTable(const RangeVar *relation, extern void RangeVarCallbackOwnsRelation(const RangeVar *relation, Oid relId, Oid oldRelId, void *noCatalogs); -#endif /* TABLECMDS_H */ +#endif /* TABLECMDS_H */ diff --git a/src/include/commands/tablespace.h b/src/include/commands/tablespace.h index 3ea13bdf14..ba8de32c7b 100644 --- a/src/include/commands/tablespace.h +++ b/src/include/commands/tablespace.h @@ -63,4 +63,4 @@ extern void tblspc_redo(XLogReaderState *rptr); extern void tblspc_desc(StringInfo buf, XLogReaderState *rptr); extern const char *tblspc_identify(uint8 info); -#endif /* TABLESPACE_H */ +#endif /* TABLESPACE_H */ diff --git a/src/include/commands/trigger.h b/src/include/commands/trigger.h index de9462d402..5061bee782 100644 --- a/src/include/commands/trigger.h +++ b/src/include/commands/trigger.h @@ -219,4 +219,4 @@ extern bool RI_Initial_Check(Trigger *trigger, extern int RI_FKey_trigger_type(Oid tgfoid); -#endif /* TRIGGER_H */ +#endif /* TRIGGER_H */ diff --git a/src/include/commands/typecmds.h b/src/include/commands/typecmds.h index c18f93adb2..34f6fe328f 100644 --- a/src/include/commands/typecmds.h +++ b/src/include/commands/typecmds.h @@ -54,4 +54,4 @@ extern Oid AlterTypeNamespaceInternal(Oid typeOid, Oid nspOid, bool errorOnTableType, ObjectAddresses *objsMoved); -#endif /* TYPECMDS_H */ +#endif /* TYPECMDS_H */ diff --git a/src/include/commands/user.h b/src/include/commands/user.h index 08037e0f81..028e0dde56 100644 --- a/src/include/commands/user.h +++ b/src/include/commands/user.h @@ -34,4 +34,4 @@ extern void DropOwnedObjects(DropOwnedStmt *stmt); extern void ReassignOwnedObjects(ReassignOwnedStmt *stmt); extern List *roleSpecsToIds(List *memberNames); -#endif /* USER_H */ +#endif /* USER_H */ diff --git a/src/include/commands/vacuum.h b/src/include/commands/vacuum.h index fd2dc860dd..307ec96cc6 100644 --- a/src/include/commands/vacuum.h +++ b/src/include/commands/vacuum.h @@ -60,12 +60,12 @@ typedef struct VacAttrStats *VacAttrStatsP; typedef Datum (*AnalyzeAttrFetchFunc) (VacAttrStatsP stats, int rownum, - bool *isNull); + bool *isNull); typedef void (*AnalyzeAttrComputeStatsFunc) (VacAttrStatsP stats, - AnalyzeAttrFetchFunc fetchfunc, - int samplerows, - double totalrows); + AnalyzeAttrFetchFunc fetchfunc, + int samplerows, + double totalrows); typedef struct VacAttrStats { @@ -137,20 +137,19 @@ typedef struct VacAttrStats typedef struct VacuumParams { int freeze_min_age; /* min freeze age, -1 to use default */ - int freeze_table_age; /* age at which to scan whole table */ - int multixact_freeze_min_age; /* min multixact freeze age, - * -1 to use default */ - int multixact_freeze_table_age; /* multixact age at which to - * scan whole table */ + int freeze_table_age; /* age at which to scan whole table */ + int multixact_freeze_min_age; /* min multixact freeze age, -1 to + * use default */ + int multixact_freeze_table_age; /* multixact age at which to scan + * whole table */ bool is_wraparound; /* force a for-wraparound vacuum */ - int log_min_duration; /* minimum execution threshold in ms - * at which verbose logs are - * activated, -1 to use default */ + int log_min_duration; /* minimum execution threshold in ms at + * which verbose logs are activated, -1 + * to use default */ } VacuumParams; /* GUC parameters */ -extern PGDLLIMPORT int default_statistics_target; /* PGDLLIMPORT for - * PostGIS */ +extern PGDLLIMPORT int default_statistics_target; /* PGDLLIMPORT for PostGIS */ extern int vacuum_freeze_min_age; extern int vacuum_freeze_table_age; extern int vacuum_multixact_freeze_min_age; @@ -208,4 +207,4 @@ extern double anl_random_fract(void); extern double anl_init_selection_state(int n); extern double anl_get_next_S(double t, int n, double *stateptr); -#endif /* VACUUM_H */ +#endif /* VACUUM_H */ diff --git a/src/include/commands/variable.h b/src/include/commands/variable.h index e0fb3332df..2e0bd3b3b2 100644 --- a/src/include/commands/variable.h +++ b/src/include/commands/variable.h @@ -42,4 +42,4 @@ extern bool check_role(char **newval, void **extra, GucSource source); extern void assign_role(const char *newval, void *extra); extern const char *show_role(void); -#endif /* VARIABLE_H */ +#endif /* VARIABLE_H */ diff --git a/src/include/commands/view.h b/src/include/commands/view.h index 39763913c8..cf08ce2ac7 100644 --- a/src/include/commands/view.h +++ b/src/include/commands/view.h @@ -24,4 +24,4 @@ extern ObjectAddress DefineView(ViewStmt *stmt, const char *queryString, extern void StoreViewQuery(Oid viewOid, Query *viewParse, bool replace); -#endif /* VIEW_H */ +#endif /* VIEW_H */ diff --git a/src/include/common/base64.h b/src/include/common/base64.h index 09b69b1656..7fe19bb432 100644 --- a/src/include/common/base64.h +++ b/src/include/common/base64.h @@ -16,4 +16,4 @@ extern int pg_b64_decode(const char *src, int len, char *dst); extern int pg_b64_enc_len(int srclen); extern int pg_b64_dec_len(int srclen); -#endif /* BASE64_H */ +#endif /* BASE64_H */ diff --git a/src/include/common/config_info.h b/src/include/common/config_info.h index 656e26fdb0..f775327861 100644 --- a/src/include/common/config_info.h +++ b/src/include/common/config_info.h @@ -18,4 +18,4 @@ typedef struct ConfigData extern ConfigData *get_configdata(const char *my_exec_path, size_t *configdata_len); -#endif /* COMMON_CONFIG_INFO_H */ +#endif /* COMMON_CONFIG_INFO_H */ diff --git a/src/include/common/controldata_utils.h b/src/include/common/controldata_utils.h index 82ea426afe..e97abe6a51 100644 --- a/src/include/common/controldata_utils.h +++ b/src/include/common/controldata_utils.h @@ -14,4 +14,4 @@ extern ControlFileData *get_controlfile(const char *DataDir, const char *progname, bool *crc_ok_p); -#endif /* COMMON_CONTROLDATA_UTILS_H */ +#endif /* COMMON_CONTROLDATA_UTILS_H */ diff --git a/src/include/common/fe_memutils.h b/src/include/common/fe_memutils.h index cb381bd9f5..6708670b96 100644 --- a/src/include/common/fe_memutils.h +++ b/src/include/common/fe_memutils.h @@ -41,4 +41,4 @@ extern void pfree(void *pointer); extern char *psprintf(const char *fmt,...) pg_attribute_printf(1, 2); extern size_t pvsnprintf(char *buf, size_t len, const char *fmt, va_list args) pg_attribute_printf(3, 0); -#endif /* FE_MEMUTILS_H */ +#endif /* FE_MEMUTILS_H */ diff --git a/src/include/common/file_utils.h b/src/include/common/file_utils.h index 95c001905d..52af7f0baa 100644 --- a/src/include/common/file_utils.h +++ b/src/include/common/file_utils.h @@ -24,4 +24,4 @@ extern int durable_rename(const char *oldfile, const char *newfile, const char *progname); extern int fsync_parent_path(const char *fname, const char *progname); -#endif /* FILE_UTILS_H */ +#endif /* FILE_UTILS_H */ diff --git a/src/include/common/int128.h b/src/include/common/int128.h index 4c46e26f40..af2c93da46 100644 --- a/src/include/common/int128.h +++ b/src/include/common/int128.h @@ -61,7 +61,7 @@ int128_add_int64(INT128 *i128, int64 v) static inline void int128_add_int64_mul_int64(INT128 *i128, int64 x, int64 y) { - *i128 += (int128) x *(int128) y; + *i128 += (int128) x * (int128) y; } /* @@ -271,6 +271,6 @@ int128_to_int64(INT128 val) return (int64) val.lo; } -#endif /* USE_NATIVE_INT128 */ +#endif /* USE_NATIVE_INT128 */ -#endif /* INT128_H */ +#endif /* INT128_H */ diff --git a/src/include/common/ip.h b/src/include/common/ip.h index 815e6ccad3..f530139876 100644 --- a/src/include/common/ip.h +++ b/src/include/common/ip.h @@ -25,13 +25,13 @@ #endif extern int pg_getaddrinfo_all(const char *hostname, const char *servname, - const struct addrinfo * hintp, - struct addrinfo ** result); -extern void pg_freeaddrinfo_all(int hint_ai_family, struct addrinfo * ai); + const struct addrinfo *hintp, + struct addrinfo **result); +extern void pg_freeaddrinfo_all(int hint_ai_family, struct addrinfo *ai); -extern int pg_getnameinfo_all(const struct sockaddr_storage * addr, int salen, +extern int pg_getnameinfo_all(const struct sockaddr_storage *addr, int salen, char *node, int nodelen, char *service, int servicelen, int flags); -#endif /* IP_H */ +#endif /* IP_H */ diff --git a/src/include/common/keywords.h b/src/include/common/keywords.h index 34e066be6b..60522715a8 100644 --- a/src/include/common/keywords.h +++ b/src/include/common/keywords.h @@ -41,4 +41,4 @@ extern const ScanKeyword *ScanKeywordLookup(const char *text, const ScanKeyword *keywords, int num_keywords); -#endif /* KEYWORDS_H */ +#endif /* KEYWORDS_H */ diff --git a/src/include/common/pg_lzcompress.h b/src/include/common/pg_lzcompress.h index dbd51d58ef..d4b2e8a53c 100644 --- a/src/include/common/pg_lzcompress.h +++ b/src/include/common/pg_lzcompress.h @@ -88,4 +88,4 @@ extern int32 pglz_compress(const char *source, int32 slen, char *dest, extern int32 pglz_decompress(const char *source, int32 slen, char *dest, int32 rawsize); -#endif /* _PG_LZCOMPRESS_H_ */ +#endif /* _PG_LZCOMPRESS_H_ */ diff --git a/src/include/common/relpath.h b/src/include/common/relpath.h index 8468c0c6f6..fb9ca3e785 100644 --- a/src/include/common/relpath.h +++ b/src/include/common/relpath.h @@ -92,4 +92,4 @@ extern char *GetRelationPath_client(Oid dbNode, Oid spcNode, Oid relNode, #define relpath(rnode, forknum) \ relpathbackend((rnode).node, (rnode).backend, forknum) #endif -#endif /* RELPATH_H */ +#endif /* RELPATH_H */ diff --git a/src/include/common/restricted_token.h b/src/include/common/restricted_token.h index 7441a55119..51be5a760c 100644 --- a/src/include/common/restricted_token.h +++ b/src/include/common/restricted_token.h @@ -21,4 +21,4 @@ void get_restricted_token(const char *progname); HANDLE CreateRestrictedProcess(char *cmd, PROCESS_INFORMATION *processInfo, const char *progname); #endif -#endif /* COMMON_RESTRICTED_TOKEN_H */ +#endif /* COMMON_RESTRICTED_TOKEN_H */ diff --git a/src/include/common/saslprep.h b/src/include/common/saslprep.h index ec5c8ce361..c7b620cf19 100644 --- a/src/include/common/saslprep.h +++ b/src/include/common/saslprep.h @@ -27,4 +27,4 @@ typedef enum extern pg_saslprep_rc pg_saslprep(const char *input, char **output); -#endif /* SASLPREP_H */ +#endif /* SASLPREP_H */ diff --git a/src/include/common/scram-common.h b/src/include/common/scram-common.h index 2ee51fbaec..ebb733df4b 100644 --- a/src/include/common/scram-common.h +++ b/src/include/common/scram-common.h @@ -56,4 +56,4 @@ extern void scram_ServerKey(const uint8 *salted_password, uint8 *result); extern char *scram_build_verifier(const char *salt, int saltlen, int iterations, const char *password); -#endif /* SCRAM_COMMON_H */ +#endif /* SCRAM_COMMON_H */ diff --git a/src/include/common/sha2.h b/src/include/common/sha2.h index 09107cfc3b..6358ca3c56 100644 --- a/src/include/common/sha2.h +++ b/src/include/common/sha2.h @@ -89,7 +89,7 @@ typedef struct pg_sha512_ctx } pg_sha512_ctx; typedef struct pg_sha256_ctx pg_sha224_ctx; typedef struct pg_sha512_ctx pg_sha384_ctx; -#endif /* USE_SSL */ +#endif /* USE_SSL */ /* Interface routines for SHA224/256/384/512 */ extern void pg_sha224_init(pg_sha224_ctx *ctx); @@ -112,4 +112,4 @@ extern void pg_sha512_update(pg_sha512_ctx *ctx, const uint8 *input0, size_t len); extern void pg_sha512_final(pg_sha512_ctx *ctx, uint8 *dest); -#endif /* _PG_SHA2_H_ */ +#endif /* _PG_SHA2_H_ */ diff --git a/src/include/common/string.h b/src/include/common/string.h index ec9ee9a740..5f3ea71d61 100644 --- a/src/include/common/string.h +++ b/src/include/common/string.h @@ -12,4 +12,4 @@ extern bool pg_str_endswith(const char *str, const char *end); -#endif /* COMMON_STRING_H */ +#endif /* COMMON_STRING_H */ diff --git a/src/include/common/unicode_norm.h b/src/include/common/unicode_norm.h index 488f964d2c..8741209751 100644 --- a/src/include/common/unicode_norm.h +++ b/src/include/common/unicode_norm.h @@ -18,4 +18,4 @@ extern pg_wchar *unicode_normalize_kc(const pg_wchar *input); -#endif /* UNICODE_NORM_H */ +#endif /* UNICODE_NORM_H */ diff --git a/src/include/common/unicode_norm_table.h b/src/include/common/unicode_norm_table.h index 3bcf05e5ee..da08e487e3 100644 --- a/src/include/common/unicode_norm_table.h +++ b/src/include/common/unicode_norm_table.h @@ -26,7 +26,8 @@ typedef struct } pg_unicode_decomposition; #define DECOMP_NO_COMPOSE 0x80 /* don't use for re-composition */ -#define DECOMP_INLINE 0x40 /* decomposition is stored inline in dec_index */ +#define DECOMP_INLINE 0x40 /* decomposition is stored inline in + * dec_index */ #define DECOMPOSITION_SIZE(x) ((x)->dec_size_flags & 0x3F) #define DECOMPOSITION_NO_COMPOSE(x) (((x)->dec_size_flags & DECOMP_NO_COMPOSE) != 0) @@ -36,14 +37,14 @@ typedef struct static const pg_unicode_decomposition UnicodeDecompMain[6532] = { {0x00A0, 0, 1 | DECOMP_INLINE, 0x0020}, - {0x00A8, 0, 2 | DECOMP_NO_COMPOSE, 0}, /* compatibility mapping */ + {0x00A8, 0, 2 | DECOMP_NO_COMPOSE, 0}, /* compatibility mapping */ {0x00AA, 0, 1 | DECOMP_INLINE, 0x0061}, - {0x00AF, 0, 2 | DECOMP_NO_COMPOSE, 2}, /* compatibility mapping */ + {0x00AF, 0, 2 | DECOMP_NO_COMPOSE, 2}, /* compatibility mapping */ {0x00B2, 0, 1 | DECOMP_INLINE, 0x0032}, {0x00B3, 0, 1 | DECOMP_INLINE, 0x0033}, - {0x00B4, 0, 2 | DECOMP_NO_COMPOSE, 4}, /* compatibility mapping */ + {0x00B4, 0, 2 | DECOMP_NO_COMPOSE, 4}, /* compatibility mapping */ {0x00B5, 0, 1 | DECOMP_INLINE, 0x03BC}, - {0x00B8, 0, 2 | DECOMP_NO_COMPOSE, 6}, /* compatibility mapping */ + {0x00B8, 0, 2 | DECOMP_NO_COMPOSE, 6}, /* compatibility mapping */ {0x00B9, 0, 1 | DECOMP_INLINE, 0x0031}, {0x00BA, 0, 1 | DECOMP_INLINE, 0x006F}, {0x00BC, 0, 3, 8}, diff --git a/src/include/common/username.h b/src/include/common/username.h index 114304f9e1..735572d382 100644 --- a/src/include/common/username.h +++ b/src/include/common/username.h @@ -12,4 +12,4 @@ extern const char *get_user_name(char **errstr); extern const char *get_user_name_or_exit(const char *progname); -#endif /* USERNAME_H */ +#endif /* USERNAME_H */ diff --git a/src/include/datatype/timestamp.h b/src/include/datatype/timestamp.h index 16e1b4c44d..6f48d1c71b 100644 --- a/src/include/datatype/timestamp.h +++ b/src/include/datatype/timestamp.h @@ -178,7 +178,7 @@ typedef struct /* First allowed date, and first disallowed date, in Julian-date form */ #define DATETIME_MIN_JULIAN (0) #define DATE_END_JULIAN (2147483494) /* == date2j(JULIAN_MAXYEAR, 1, 1) */ -#define TIMESTAMP_END_JULIAN (109203528) /* == date2j(294277, 1, 1) */ +#define TIMESTAMP_END_JULIAN (109203528) /* == date2j(294277, 1, 1) */ /* Timestamp limits */ #define MIN_TIMESTAMP INT64CONST(-211813488000000000) @@ -194,4 +194,4 @@ typedef struct /* Range-check a timestamp */ #define IS_VALID_TIMESTAMP(t) (MIN_TIMESTAMP <= (t) && (t) < END_TIMESTAMP) -#endif /* DATATYPE_TIMESTAMP_H */ +#endif /* DATATYPE_TIMESTAMP_H */ diff --git a/src/include/executor/execExpr.h b/src/include/executor/execExpr.h index 86fdb33cd3..7a65339f01 100644 --- a/src/include/executor/execExpr.h +++ b/src/include/executor/execExpr.h @@ -261,7 +261,7 @@ typedef struct ExprEvalStep bool first; /* first time through, need to initialize? */ bool slow; /* need runtime check for nulls? */ TupleDesc tupdesc; /* descriptor for resulting tuples */ - JunkFilter *junkFilter; /* JunkFilter to remove resjunk cols */ + JunkFilter *junkFilter; /* JunkFilter to remove resjunk cols */ } wholerow; /* for EEOP_ASSIGN_*_VAR */ @@ -292,7 +292,7 @@ typedef struct ExprEvalStep struct { FmgrInfo *finfo; /* function's lookup data */ - FunctionCallInfo fcinfo_data; /* arguments etc */ + FunctionCallInfo fcinfo_data; /* arguments etc */ /* faster to access without additional indirection: */ PGFunction fn_addr; /* actual call address */ int nargs; /* number of arguments */ @@ -302,19 +302,19 @@ typedef struct ExprEvalStep struct { bool *anynull; /* track if any input was NULL */ - int jumpdone; /* jump here if result determined */ + int jumpdone; /* jump here if result determined */ } boolexpr; /* for EEOP_QUAL */ struct { - int jumpdone; /* jump here on false or null */ + int jumpdone; /* jump here on false or null */ } qualexpr; /* for EEOP_JUMP[_CONDITION] */ struct { - int jumpdone; /* target instruction's index */ + int jumpdone; /* target instruction's index */ } jump; /* for EEOP_NULLTEST_ROWIS[NOT]NULL */ @@ -328,7 +328,7 @@ typedef struct ExprEvalStep struct { int paramid; /* numeric ID for parameter */ - Oid paramtype; /* OID of parameter's datatype */ + Oid paramtype; /* OID of parameter's datatype */ } param; /* for EEOP_CASE_TESTVAL/DOMAIN_TESTVAL */ @@ -372,14 +372,14 @@ typedef struct ExprEvalStep /* for EEOP_ARRAYEXPR */ struct { - Datum *elemvalues; /* element values get stored here */ + Datum *elemvalues; /* element values get stored here */ bool *elemnulls; int nelems; /* length of the above arrays */ - Oid elemtype; /* array element type */ - int16 elemlength; /* typlen of the array element type */ - bool elembyval; /* is the element type pass-by-value? */ - char elemalign; /* typalign of the element type */ - bool multidims; /* is array expression multi-D? */ + Oid elemtype; /* array element type */ + int16 elemlength; /* typlen of the array element type */ + bool elembyval; /* is the element type pass-by-value? */ + char elemalign; /* typalign of the element type */ + bool multidims; /* is array expression multi-D? */ } arrayexpr; /* for EEOP_ARRAYCOERCE */ @@ -387,9 +387,9 @@ typedef struct ExprEvalStep { ArrayCoerceExpr *coerceexpr; Oid resultelemtype; /* element type of result array */ - FmgrInfo *elemfunc; /* lookup info for element coercion - * function */ - struct ArrayMapState *amstate; /* workspace for array_map */ + FmgrInfo *elemfunc; /* lookup info for element coercion + * function */ + struct ArrayMapState *amstate; /* workspace for array_map */ } arraycoerce; /* for EEOP_ROW */ @@ -437,8 +437,8 @@ typedef struct ExprEvalStep /* for EEOP_FIELDSELECT */ struct { - AttrNumber fieldnum; /* field number to extract */ - Oid resulttype; /* field's type */ + AttrNumber fieldnum; /* field number to extract */ + Oid resulttype; /* field's type */ /* cached tupdesc pointer - filled at runtime */ TupleDesc argdesc; } fieldselect; @@ -466,7 +466,7 @@ typedef struct ExprEvalStep struct ArrayRefState *state; int off; /* 0-based index of this subscript */ bool isupper; /* is it upper or lower subscript? */ - int jumpdone; /* jump here on null */ + int jumpdone; /* jump here on null */ } arrayref_subscript; /* for EEOP_ARRAYREF_OLD / ASSIGN / FETCH */ @@ -491,7 +491,7 @@ typedef struct ExprEvalStep /* for EEOP_CONVERT_ROWTYPE */ struct { - ConvertRowtypeExpr *convert; /* original expression */ + ConvertRowtypeExpr *convert; /* original expression */ /* these three fields are filled at runtime: */ TupleDesc indesc; /* tupdesc for input type */ TupleDesc outdesc; /* tupdesc for output type */ @@ -509,7 +509,7 @@ typedef struct ExprEvalStep bool typbyval; char typalign; FmgrInfo *finfo; /* function's lookup data */ - FunctionCallInfo fcinfo_data; /* arguments etc */ + FunctionCallInfo fcinfo_data; /* arguments etc */ /* faster to access without additional indirection: */ PGFunction fn_addr; /* actual call address */ } scalararrayop; @@ -647,4 +647,4 @@ extern void ExecEvalAlternativeSubPlan(ExprState *state, ExprEvalStep *op, extern void ExecEvalWholeRowVar(ExprState *state, ExprEvalStep *op, ExprContext *econtext); -#endif /* EXEC_EXPR_H */ +#endif /* EXEC_EXPR_H */ diff --git a/src/include/executor/execParallel.h b/src/include/executor/execParallel.h index 0b7ca59dca..bd0a87fa04 100644 --- a/src/include/executor/execParallel.h +++ b/src/include/executor/execParallel.h @@ -40,4 +40,4 @@ extern void ExecParallelReinitialize(ParallelExecutorInfo *pei); extern void ParallelQueryMain(dsm_segment *seg, shm_toc *toc); -#endif /* EXECPARALLEL_H */ +#endif /* EXECPARALLEL_H */ diff --git a/src/include/executor/execdebug.h b/src/include/executor/execdebug.h index 8b61520e18..cd04b60176 100644 --- a/src/include/executor/execdebug.h +++ b/src/include/executor/execdebug.h @@ -76,7 +76,7 @@ #define NL_printf(s) #define NL1_printf(s, a) #define ENL1_printf(message) -#endif /* EXEC_NESTLOOPDEBUG */ +#endif /* EXEC_NESTLOOPDEBUG */ /* ---------------- * sort node debugging defines @@ -90,7 +90,7 @@ #define SO_nodeDisplay(l) #define SO_printf(s) #define SO1_printf(s, p) -#endif /* EXEC_SORTDEBUG */ +#endif /* EXEC_SORTDEBUG */ /* ---------------- * merge join debugging defines @@ -123,6 +123,6 @@ #define MJ_DEBUG_COMPARE(res) #define MJ_DEBUG_QUAL(clause, res) #define MJ_DEBUG_PROC_NODE(slot) -#endif /* EXEC_MERGEJOINDEBUG */ +#endif /* EXEC_MERGEJOINDEBUG */ -#endif /* EXECDEBUG_H */ +#endif /* EXECDEBUG_H */ diff --git a/src/include/executor/execdesc.h b/src/include/executor/execdesc.h index 62a2f2e477..a4b0609e2c 100644 --- a/src/include/executor/execdesc.h +++ b/src/include/executor/execdesc.h @@ -44,7 +44,7 @@ typedef struct QueryDesc DestReceiver *dest; /* the destination for tuple output */ ParamListInfo params; /* param values being passed in */ QueryEnvironment *queryEnv; /* query environment passed in */ - int instrument_options; /* OR of InstrumentOption flags */ + int instrument_options; /* OR of InstrumentOption flags */ /* These fields are set by ExecutorStart */ TupleDesc tupDesc; /* descriptor for result tuples */ @@ -59,7 +59,7 @@ typedef struct QueryDesc * get local data from squeue */ #endif /* This field is set by ExecutorRun */ - bool already_executed; /* true if previously executed */ + bool already_executed; /* true if previously executed */ /* This is always set NULL by the core system, but plugins can change it */ struct Instrumentation *totaltime; /* total time spent in ExecutorRun */ @@ -77,4 +77,4 @@ extern QueryDesc *CreateQueryDesc(PlannedStmt *plannedstmt, extern void FreeQueryDesc(QueryDesc *qdesc); -#endif /* EXECDESC_H */ +#endif /* EXECDESC_H */ diff --git a/src/include/executor/executor.h b/src/include/executor/executor.h index fdf7c15b70..83bc1bc2a4 100644 --- a/src/include/executor/executor.h +++ b/src/include/executor/executor.h @@ -76,9 +76,9 @@ extern PGDLLIMPORT ExecutorStart_hook_type ExecutorStart_hook; /* Hook for plugins to get control in ExecutorRun() */ typedef void (*ExecutorRun_hook_type) (QueryDesc *queryDesc, - ScanDirection direction, - uint64 count, - bool execute_once); + ScanDirection direction, + uint64 count, + bool execute_once); extern PGDLLIMPORT ExecutorRun_hook_type ExecutorRun_hook; /* Hook for plugins to get control in ExecutorFinish() */ @@ -179,7 +179,7 @@ extern void standard_ExecutorStart(QueryDesc *queryDesc, int eflags); extern void ExecutorRun(QueryDesc *queryDesc, ScanDirection direction, uint64 count, bool execute_once); extern void standard_ExecutorRun(QueryDesc *queryDesc, - ScanDirection direction, uint64 count, bool execute_once); + ScanDirection direction, uint64 count, bool execute_once); extern void ExecutorFinish(QueryDesc *queryDesc); extern void standard_ExecutorFinish(QueryDesc *queryDesc); extern void ExecutorEnd(QueryDesc *queryDesc); @@ -550,4 +550,4 @@ extern void CheckCmdReplicaIdentity(Relation rel, CmdType cmd); extern void CheckSubscriptionRelkind(char relkind, const char *nspname, const char *relname); -#endif /* EXECUTOR_H */ +#endif /* EXECUTOR_H */ diff --git a/src/include/executor/functions.h b/src/include/executor/functions.h index 7821a634f1..718d8947a3 100644 --- a/src/include/executor/functions.h +++ b/src/include/executor/functions.h @@ -36,4 +36,4 @@ extern bool check_sql_fn_retval(Oid func_id, Oid rettype, extern DestReceiver *CreateSQLFunctionDestReceiver(void); -#endif /* FUNCTIONS_H */ +#endif /* FUNCTIONS_H */ diff --git a/src/include/executor/hashjoin.h b/src/include/executor/hashjoin.h index ac840533ee..82acadf85b 100644 --- a/src/include/executor/hashjoin.h +++ b/src/include/executor/hashjoin.h @@ -63,10 +63,10 @@ typedef struct HashJoinTupleData { - struct HashJoinTupleData *next; /* link to next tuple in same bucket */ + struct HashJoinTupleData *next; /* link to next tuple in same bucket */ uint32 hashvalue; /* tuple's hash code */ /* Tuple data, in MinimalTuple format, follows on a MAXALIGN boundary */ -} HashJoinTupleData; +} HashJoinTupleData; #define HJTUPLE_OVERHEAD MAXALIGN(sizeof(HashJoinTupleData)) #define HJTUPLE_MINTUPLE(hjtup) \ @@ -116,7 +116,7 @@ typedef struct HashMemoryChunkData * list) */ char data[FLEXIBLE_ARRAY_MEMBER]; /* buffer allocated at the end */ -} HashMemoryChunkData; +} HashMemoryChunkData; typedef struct HashMemoryChunkData *HashMemoryChunk; @@ -128,9 +128,8 @@ typedef struct HashJoinTableData int nbuckets; /* # buckets in the in-memory hash table */ int log2_nbuckets; /* its log2 (nbuckets must be a power of 2) */ - int nbuckets_original; /* # buckets when starting the first - * hash */ - int nbuckets_optimal; /* optimal # buckets (per batch) */ + int nbuckets_original; /* # buckets when starting the first hash */ + int nbuckets_optimal; /* optimal # buckets (per batch) */ int log2_nbuckets_optimal; /* log2(nbuckets_optimal) */ /* buckets[i] is head of list of tuples in i'th in-memory bucket */ @@ -179,13 +178,13 @@ typedef struct HashJoinTableData Size spaceAllowed; /* upper limit for space used */ Size spacePeak; /* peak space used */ Size spaceUsedSkew; /* skew hash table's current space usage */ - Size spaceAllowedSkew; /* upper limit for skew hashtable */ + Size spaceAllowedSkew; /* upper limit for skew hashtable */ MemoryContext hashCxt; /* context for whole-hash-join storage */ MemoryContext batchCxt; /* context for this-batch-only storage */ /* used for dense allocation of tuples (into linked chunks) */ HashMemoryChunk chunks; /* one list for the whole batch */ -} HashJoinTableData; +} HashJoinTableData; -#endif /* HASHJOIN_H */ +#endif /* HASHJOIN_H */ diff --git a/src/include/executor/instrument.h b/src/include/executor/instrument.h index c9e169c45c..31573145a9 100644 --- a/src/include/executor/instrument.h +++ b/src/include/executor/instrument.h @@ -19,15 +19,15 @@ typedef struct BufferUsage { long shared_blks_hit; /* # of shared buffer hits */ - long shared_blks_read; /* # of shared disk blocks read */ + long shared_blks_read; /* # of shared disk blocks read */ long shared_blks_dirtied; /* # of shared blocks dirtied */ long shared_blks_written; /* # of shared disk blocks written */ long local_blks_hit; /* # of local buffer hits */ long local_blks_read; /* # of local disk blocks read */ - long local_blks_dirtied; /* # of shared blocks dirtied */ - long local_blks_written; /* # of local disk blocks written */ + long local_blks_dirtied; /* # of shared blocks dirtied */ + long local_blks_written; /* # of local disk blocks written */ long temp_blks_read; /* # of temp blocks read */ - long temp_blks_written; /* # of temp blocks written */ + long temp_blks_written; /* # of temp blocks written */ instr_time blk_read_time; /* time spent reading */ instr_time blk_write_time; /* time spent writing */ } BufferUsage; @@ -81,4 +81,4 @@ extern void InstrStartParallelQuery(void); extern void InstrEndParallelQuery(BufferUsage *result); extern void InstrAccumParallelQuery(BufferUsage *result); -#endif /* INSTRUMENT_H */ +#endif /* INSTRUMENT_H */ diff --git a/src/include/executor/nodeAgg.h b/src/include/executor/nodeAgg.h index d2fee52e12..fa11ba93a6 100644 --- a/src/include/executor/nodeAgg.h +++ b/src/include/executor/nodeAgg.h @@ -25,4 +25,4 @@ extern Size hash_agg_entry_size(int numAggs); extern Datum aggregate_dummy(PG_FUNCTION_ARGS); -#endif /* NODEAGG_H */ +#endif /* NODEAGG_H */ diff --git a/src/include/executor/nodeAppend.h b/src/include/executor/nodeAppend.h index 6fb4662c88..ee0b6ad23d 100644 --- a/src/include/executor/nodeAppend.h +++ b/src/include/executor/nodeAppend.h @@ -21,4 +21,4 @@ extern TupleTableSlot *ExecAppend(AppendState *node); extern void ExecEndAppend(AppendState *node); extern void ExecReScanAppend(AppendState *node); -#endif /* NODEAPPEND_H */ +#endif /* NODEAPPEND_H */ diff --git a/src/include/executor/nodeBitmapAnd.h b/src/include/executor/nodeBitmapAnd.h index 1cb3470bcb..5d848b61af 100644 --- a/src/include/executor/nodeBitmapAnd.h +++ b/src/include/executor/nodeBitmapAnd.h @@ -21,4 +21,4 @@ extern Node *MultiExecBitmapAnd(BitmapAndState *node); extern void ExecEndBitmapAnd(BitmapAndState *node); extern void ExecReScanBitmapAnd(BitmapAndState *node); -#endif /* NODEBITMAPAND_H */ +#endif /* NODEBITMAPAND_H */ diff --git a/src/include/executor/nodeBitmapHeapscan.h b/src/include/executor/nodeBitmapHeapscan.h index 465c58e6ee..f477d1c772 100644 --- a/src/include/executor/nodeBitmapHeapscan.h +++ b/src/include/executor/nodeBitmapHeapscan.h @@ -28,4 +28,4 @@ extern void ExecBitmapHeapInitializeDSM(BitmapHeapScanState *node, extern void ExecBitmapHeapInitializeWorker(BitmapHeapScanState *node, shm_toc *toc); -#endif /* NODEBITMAPHEAPSCAN_H */ +#endif /* NODEBITMAPHEAPSCAN_H */ diff --git a/src/include/executor/nodeBitmapIndexscan.h b/src/include/executor/nodeBitmapIndexscan.h index 1fb8da01cb..842193f4df 100644 --- a/src/include/executor/nodeBitmapIndexscan.h +++ b/src/include/executor/nodeBitmapIndexscan.h @@ -21,4 +21,4 @@ extern Node *MultiExecBitmapIndexScan(BitmapIndexScanState *node); extern void ExecEndBitmapIndexScan(BitmapIndexScanState *node); extern void ExecReScanBitmapIndexScan(BitmapIndexScanState *node); -#endif /* NODEBITMAPINDEXSCAN_H */ +#endif /* NODEBITMAPINDEXSCAN_H */ diff --git a/src/include/executor/nodeBitmapOr.h b/src/include/executor/nodeBitmapOr.h index a23bf77ff7..526904eb4d 100644 --- a/src/include/executor/nodeBitmapOr.h +++ b/src/include/executor/nodeBitmapOr.h @@ -21,4 +21,4 @@ extern Node *MultiExecBitmapOr(BitmapOrState *node); extern void ExecEndBitmapOr(BitmapOrState *node); extern void ExecReScanBitmapOr(BitmapOrState *node); -#endif /* NODEBITMAPOR_H */ +#endif /* NODEBITMAPOR_H */ diff --git a/src/include/executor/nodeCtescan.h b/src/include/executor/nodeCtescan.h index e8bcb88b35..397bdfdd1c 100644 --- a/src/include/executor/nodeCtescan.h +++ b/src/include/executor/nodeCtescan.h @@ -21,4 +21,4 @@ extern TupleTableSlot *ExecCteScan(CteScanState *node); extern void ExecEndCteScan(CteScanState *node); extern void ExecReScanCteScan(CteScanState *node); -#endif /* NODECTESCAN_H */ +#endif /* NODECTESCAN_H */ diff --git a/src/include/executor/nodeCustom.h b/src/include/executor/nodeCustom.h index c2f2ca1eed..e81bcf7f21 100644 --- a/src/include/executor/nodeCustom.h +++ b/src/include/executor/nodeCustom.h @@ -39,4 +39,4 @@ extern void ExecCustomScanInitializeWorker(CustomScanState *node, shm_toc *toc); extern void ExecShutdownCustomScan(CustomScanState *node); -#endif /* NODECUSTOM_H */ +#endif /* NODECUSTOM_H */ diff --git a/src/include/executor/nodeForeignscan.h b/src/include/executor/nodeForeignscan.h index 1b167b8143..3ff4ecd8c9 100644 --- a/src/include/executor/nodeForeignscan.h +++ b/src/include/executor/nodeForeignscan.h @@ -30,4 +30,4 @@ extern void ExecForeignScanInitializeWorker(ForeignScanState *node, shm_toc *toc); extern void ExecShutdownForeignScan(ForeignScanState *node); -#endif /* NODEFOREIGNSCAN_H */ +#endif /* NODEFOREIGNSCAN_H */ diff --git a/src/include/executor/nodeFunctionscan.h b/src/include/executor/nodeFunctionscan.h index efff0deaee..5e830ebdea 100644 --- a/src/include/executor/nodeFunctionscan.h +++ b/src/include/executor/nodeFunctionscan.h @@ -21,4 +21,4 @@ extern TupleTableSlot *ExecFunctionScan(FunctionScanState *node); extern void ExecEndFunctionScan(FunctionScanState *node); extern void ExecReScanFunctionScan(FunctionScanState *node); -#endif /* NODEFUNCTIONSCAN_H */ +#endif /* NODEFUNCTIONSCAN_H */ diff --git a/src/include/executor/nodeGather.h b/src/include/executor/nodeGather.h index e19bc9b20d..b0006934d4 100644 --- a/src/include/executor/nodeGather.h +++ b/src/include/executor/nodeGather.h @@ -22,4 +22,4 @@ extern void ExecEndGather(GatherState *node); extern void ExecShutdownGather(GatherState *node); extern void ExecReScanGather(GatherState *node); -#endif /* NODEGATHER_H */ +#endif /* NODEGATHER_H */ diff --git a/src/include/executor/nodeGatherMerge.h b/src/include/executor/nodeGatherMerge.h index f5ba353762..14b31a086c 100644 --- a/src/include/executor/nodeGatherMerge.h +++ b/src/include/executor/nodeGatherMerge.h @@ -24,4 +24,4 @@ extern void ExecEndGatherMerge(GatherMergeState *node); extern void ExecReScanGatherMerge(GatherMergeState *node); extern void ExecShutdownGatherMerge(GatherMergeState *node); -#endif /* NODEGATHERMERGE_H */ +#endif /* NODEGATHERMERGE_H */ diff --git a/src/include/executor/nodeGroup.h b/src/include/executor/nodeGroup.h index a9536a3c6f..7358b61707 100644 --- a/src/include/executor/nodeGroup.h +++ b/src/include/executor/nodeGroup.h @@ -21,4 +21,4 @@ extern TupleTableSlot *ExecGroup(GroupState *node); extern void ExecEndGroup(GroupState *node); extern void ExecReScanGroup(GroupState *node); -#endif /* NODEGROUP_H */ +#endif /* NODEGROUP_H */ diff --git a/src/include/executor/nodeHash.h b/src/include/executor/nodeHash.h index fe5c2642d7..8052f27d0b 100644 --- a/src/include/executor/nodeHash.h +++ b/src/include/executor/nodeHash.h @@ -50,4 +50,4 @@ extern void ExecChooseHashTableSize(double ntuples, int tupwidth, bool useskew, int *num_skew_mcvs); extern int ExecHashGetSkewBucket(HashJoinTable hashtable, uint32 hashvalue); -#endif /* NODEHASH_H */ +#endif /* NODEHASH_H */ diff --git a/src/include/executor/nodeHashjoin.h b/src/include/executor/nodeHashjoin.h index ddc32b1de3..541c81edc7 100644 --- a/src/include/executor/nodeHashjoin.h +++ b/src/include/executor/nodeHashjoin.h @@ -25,4 +25,4 @@ extern void ExecReScanHashJoin(HashJoinState *node); extern void ExecHashJoinSaveTuple(MinimalTuple tuple, uint32 hashvalue, BufFile **fileptr); -#endif /* NODEHASHJOIN_H */ +#endif /* NODEHASHJOIN_H */ diff --git a/src/include/executor/nodeIndexonlyscan.h b/src/include/executor/nodeIndexonlyscan.h index 5d3c6bbc0d..cf227daae0 100644 --- a/src/include/executor/nodeIndexonlyscan.h +++ b/src/include/executor/nodeIndexonlyscan.h @@ -32,4 +32,4 @@ extern void ExecIndexOnlyScanInitializeDSM(IndexOnlyScanState *node, extern void ExecIndexOnlyScanInitializeWorker(IndexOnlyScanState *node, shm_toc *toc); -#endif /* NODEINDEXONLYSCAN_H */ +#endif /* NODEINDEXONLYSCAN_H */ diff --git a/src/include/executor/nodeIndexscan.h b/src/include/executor/nodeIndexscan.h index ea3f3a5cc4..0118234eca 100644 --- a/src/include/executor/nodeIndexscan.h +++ b/src/include/executor/nodeIndexscan.h @@ -37,9 +37,9 @@ extern void ExecIndexBuildScanKeys(PlanState *planstate, Relation index, IndexRuntimeKeyInfo **runtimeKeys, int *numRuntimeKeys, IndexArrayKeyInfo **arrayKeys, int *numArrayKeys); extern void ExecIndexEvalRuntimeKeys(ExprContext *econtext, - IndexRuntimeKeyInfo *runtimeKeys, int numRuntimeKeys); + IndexRuntimeKeyInfo *runtimeKeys, int numRuntimeKeys); extern bool ExecIndexEvalArrayKeys(ExprContext *econtext, IndexArrayKeyInfo *arrayKeys, int numArrayKeys); extern bool ExecIndexAdvanceArrayKeys(IndexArrayKeyInfo *arrayKeys, int numArrayKeys); -#endif /* NODEINDEXSCAN_H */ +#endif /* NODEINDEXSCAN_H */ diff --git a/src/include/executor/nodeLimit.h b/src/include/executor/nodeLimit.h index 6e4084b46d..7bb20d9978 100644 --- a/src/include/executor/nodeLimit.h +++ b/src/include/executor/nodeLimit.h @@ -21,4 +21,4 @@ extern TupleTableSlot *ExecLimit(LimitState *node); extern void ExecEndLimit(LimitState *node); extern void ExecReScanLimit(LimitState *node); -#endif /* NODELIMIT_H */ +#endif /* NODELIMIT_H */ diff --git a/src/include/executor/nodeLockRows.h b/src/include/executor/nodeLockRows.h index c23954131b..6b90756e4c 100644 --- a/src/include/executor/nodeLockRows.h +++ b/src/include/executor/nodeLockRows.h @@ -21,4 +21,4 @@ extern TupleTableSlot *ExecLockRows(LockRowsState *node); extern void ExecEndLockRows(LockRowsState *node); extern void ExecReScanLockRows(LockRowsState *node); -#endif /* NODELOCKROWS_H */ +#endif /* NODELOCKROWS_H */ diff --git a/src/include/executor/nodeMaterial.h b/src/include/executor/nodeMaterial.h index f6a7241ee7..f69abbca82 100644 --- a/src/include/executor/nodeMaterial.h +++ b/src/include/executor/nodeMaterial.h @@ -23,4 +23,4 @@ extern void ExecMaterialMarkPos(MaterialState *node); extern void ExecMaterialRestrPos(MaterialState *node); extern void ExecReScanMaterial(MaterialState *node); -#endif /* NODEMATERIAL_H */ +#endif /* NODEMATERIAL_H */ diff --git a/src/include/executor/nodeMergeAppend.h b/src/include/executor/nodeMergeAppend.h index eafa15445c..3cc6ef549b 100644 --- a/src/include/executor/nodeMergeAppend.h +++ b/src/include/executor/nodeMergeAppend.h @@ -21,4 +21,4 @@ extern TupleTableSlot *ExecMergeAppend(MergeAppendState *node); extern void ExecEndMergeAppend(MergeAppendState *node); extern void ExecReScanMergeAppend(MergeAppendState *node); -#endif /* NODEMERGEAPPEND_H */ +#endif /* NODEMERGEAPPEND_H */ diff --git a/src/include/executor/nodeMergejoin.h b/src/include/executor/nodeMergejoin.h index ffaa3af908..32df25ae8b 100644 --- a/src/include/executor/nodeMergejoin.h +++ b/src/include/executor/nodeMergejoin.h @@ -21,4 +21,4 @@ extern TupleTableSlot *ExecMergeJoin(MergeJoinState *node); extern void ExecEndMergeJoin(MergeJoinState *node); extern void ExecReScanMergeJoin(MergeJoinState *node); -#endif /* NODEMERGEJOIN_H */ +#endif /* NODEMERGEJOIN_H */ diff --git a/src/include/executor/nodeModifyTable.h b/src/include/executor/nodeModifyTable.h index 0c327768e1..5a406f236d 100644 --- a/src/include/executor/nodeModifyTable.h +++ b/src/include/executor/nodeModifyTable.h @@ -20,4 +20,4 @@ extern TupleTableSlot *ExecModifyTable(ModifyTableState *node); extern void ExecEndModifyTable(ModifyTableState *node); extern void ExecReScanModifyTable(ModifyTableState *node); -#endif /* NODEMODIFYTABLE_H */ +#endif /* NODEMODIFYTABLE_H */ diff --git a/src/include/executor/nodeNamedtuplestorescan.h b/src/include/executor/nodeNamedtuplestorescan.h index 9ef477e7ff..7f72fbe98a 100644 --- a/src/include/executor/nodeNamedtuplestorescan.h +++ b/src/include/executor/nodeNamedtuplestorescan.h @@ -21,4 +21,4 @@ extern TupleTableSlot *ExecNamedTuplestoreScan(NamedTuplestoreScanState *node); extern void ExecEndNamedTuplestoreScan(NamedTuplestoreScanState *node); extern void ExecReScanNamedTuplestoreScan(NamedTuplestoreScanState *node); -#endif /* NODENAMEDTUPLESTORESCAN_H */ +#endif /* NODENAMEDTUPLESTORESCAN_H */ diff --git a/src/include/executor/nodeNestloop.h b/src/include/executor/nodeNestloop.h index 4b2bf59050..8e0fcc1922 100644 --- a/src/include/executor/nodeNestloop.h +++ b/src/include/executor/nodeNestloop.h @@ -21,4 +21,4 @@ extern TupleTableSlot *ExecNestLoop(NestLoopState *node); extern void ExecEndNestLoop(NestLoopState *node); extern void ExecReScanNestLoop(NestLoopState *node); -#endif /* NODENESTLOOP_H */ +#endif /* NODENESTLOOP_H */ diff --git a/src/include/executor/nodeProjectSet.h b/src/include/executor/nodeProjectSet.h index 30b2b7cec9..2f6999e8db 100644 --- a/src/include/executor/nodeProjectSet.h +++ b/src/include/executor/nodeProjectSet.h @@ -21,4 +21,4 @@ extern TupleTableSlot *ExecProjectSet(ProjectSetState *node); extern void ExecEndProjectSet(ProjectSetState *node); extern void ExecReScanProjectSet(ProjectSetState *node); -#endif /* NODEPROJECTSET_H */ +#endif /* NODEPROJECTSET_H */ diff --git a/src/include/executor/nodeRecursiveunion.h b/src/include/executor/nodeRecursiveunion.h index 066596f773..f0eba05bee 100644 --- a/src/include/executor/nodeRecursiveunion.h +++ b/src/include/executor/nodeRecursiveunion.h @@ -21,4 +21,4 @@ extern TupleTableSlot *ExecRecursiveUnion(RecursiveUnionState *node); extern void ExecEndRecursiveUnion(RecursiveUnionState *node); extern void ExecReScanRecursiveUnion(RecursiveUnionState *node); -#endif /* NODERECURSIVEUNION_H */ +#endif /* NODERECURSIVEUNION_H */ diff --git a/src/include/executor/nodeResult.h b/src/include/executor/nodeResult.h index 8e547b77e9..61d3cb2cc2 100644 --- a/src/include/executor/nodeResult.h +++ b/src/include/executor/nodeResult.h @@ -23,4 +23,4 @@ extern void ExecResultMarkPos(ResultState *node); extern void ExecResultRestrPos(ResultState *node); extern void ExecReScanResult(ResultState *node); -#endif /* NODERESULT_H */ +#endif /* NODERESULT_H */ diff --git a/src/include/executor/nodeSamplescan.h b/src/include/executor/nodeSamplescan.h index 8baf3a355c..ed06e77e4e 100644 --- a/src/include/executor/nodeSamplescan.h +++ b/src/include/executor/nodeSamplescan.h @@ -21,4 +21,4 @@ extern TupleTableSlot *ExecSampleScan(SampleScanState *node); extern void ExecEndSampleScan(SampleScanState *node); extern void ExecReScanSampleScan(SampleScanState *node); -#endif /* NODESAMPLESCAN_H */ +#endif /* NODESAMPLESCAN_H */ diff --git a/src/include/executor/nodeSeqscan.h b/src/include/executor/nodeSeqscan.h index 92b305e138..06e0686b0b 100644 --- a/src/include/executor/nodeSeqscan.h +++ b/src/include/executor/nodeSeqscan.h @@ -27,4 +27,4 @@ extern void ExecSeqScanEstimate(SeqScanState *node, ParallelContext *pcxt); extern void ExecSeqScanInitializeDSM(SeqScanState *node, ParallelContext *pcxt); extern void ExecSeqScanInitializeWorker(SeqScanState *node, shm_toc *toc); -#endif /* NODESEQSCAN_H */ +#endif /* NODESEQSCAN_H */ diff --git a/src/include/executor/nodeSetOp.h b/src/include/executor/nodeSetOp.h index 887bdc1a42..af85977183 100644 --- a/src/include/executor/nodeSetOp.h +++ b/src/include/executor/nodeSetOp.h @@ -21,4 +21,4 @@ extern TupleTableSlot *ExecSetOp(SetOpState *node); extern void ExecEndSetOp(SetOpState *node); extern void ExecReScanSetOp(SetOpState *node); -#endif /* NODESETOP_H */ +#endif /* NODESETOP_H */ diff --git a/src/include/executor/nodeSort.h b/src/include/executor/nodeSort.h index 10d16b47b1..1d2b7130b3 100644 --- a/src/include/executor/nodeSort.h +++ b/src/include/executor/nodeSort.h @@ -23,4 +23,4 @@ extern void ExecSortMarkPos(SortState *node); extern void ExecSortRestrPos(SortState *node); extern void ExecReScanSort(SortState *node); -#endif /* NODESORT_H */ +#endif /* NODESORT_H */ diff --git a/src/include/executor/nodeSubplan.h b/src/include/executor/nodeSubplan.h index 0d3f52118b..5dbaeeb29a 100644 --- a/src/include/executor/nodeSubplan.h +++ b/src/include/executor/nodeSubplan.h @@ -28,4 +28,4 @@ extern void ExecReScanSetParamPlan(SubPlanState *node, PlanState *parent); extern void ExecSetParamPlan(SubPlanState *node, ExprContext *econtext); -#endif /* NODESUBPLAN_H */ +#endif /* NODESUBPLAN_H */ diff --git a/src/include/executor/nodeSubqueryscan.h b/src/include/executor/nodeSubqueryscan.h index c2a0f707a6..c852e2947f 100644 --- a/src/include/executor/nodeSubqueryscan.h +++ b/src/include/executor/nodeSubqueryscan.h @@ -21,4 +21,4 @@ extern TupleTableSlot *ExecSubqueryScan(SubqueryScanState *node); extern void ExecEndSubqueryScan(SubqueryScanState *node); extern void ExecReScanSubqueryScan(SubqueryScanState *node); -#endif /* NODESUBQUERYSCAN_H */ +#endif /* NODESUBQUERYSCAN_H */ diff --git a/src/include/executor/nodeTableFuncscan.h b/src/include/executor/nodeTableFuncscan.h index 529c929993..c58156e99c 100644 --- a/src/include/executor/nodeTableFuncscan.h +++ b/src/include/executor/nodeTableFuncscan.h @@ -21,4 +21,4 @@ extern TupleTableSlot *ExecTableFuncScan(TableFuncScanState *node); extern void ExecEndTableFuncScan(TableFuncScanState *node); extern void ExecReScanTableFuncScan(TableFuncScanState *node); -#endif /* NODETABLEFUNCSCAN_H */ +#endif /* NODETABLEFUNCSCAN_H */ diff --git a/src/include/executor/nodeTidscan.h b/src/include/executor/nodeTidscan.h index 3186ca8cff..d07ed7c864 100644 --- a/src/include/executor/nodeTidscan.h +++ b/src/include/executor/nodeTidscan.h @@ -21,4 +21,4 @@ extern TupleTableSlot *ExecTidScan(TidScanState *node); extern void ExecEndTidScan(TidScanState *node); extern void ExecReScanTidScan(TidScanState *node); -#endif /* NODETIDSCAN_H */ +#endif /* NODETIDSCAN_H */ diff --git a/src/include/executor/nodeUnique.h b/src/include/executor/nodeUnique.h index 66ad898397..3d0ac9dde1 100644 --- a/src/include/executor/nodeUnique.h +++ b/src/include/executor/nodeUnique.h @@ -21,4 +21,4 @@ extern TupleTableSlot *ExecUnique(UniqueState *node); extern void ExecEndUnique(UniqueState *node); extern void ExecReScanUnique(UniqueState *node); -#endif /* NODEUNIQUE_H */ +#endif /* NODEUNIQUE_H */ diff --git a/src/include/executor/nodeValuesscan.h b/src/include/executor/nodeValuesscan.h index 6c2af73b1f..c28bb1acce 100644 --- a/src/include/executor/nodeValuesscan.h +++ b/src/include/executor/nodeValuesscan.h @@ -21,4 +21,4 @@ extern TupleTableSlot *ExecValuesScan(ValuesScanState *node); extern void ExecEndValuesScan(ValuesScanState *node); extern void ExecReScanValuesScan(ValuesScanState *node); -#endif /* NODEVALUESSCAN_H */ +#endif /* NODEVALUESSCAN_H */ diff --git a/src/include/executor/nodeWindowAgg.h b/src/include/executor/nodeWindowAgg.h index 11d2dba2c5..db1ad60677 100644 --- a/src/include/executor/nodeWindowAgg.h +++ b/src/include/executor/nodeWindowAgg.h @@ -21,4 +21,4 @@ extern TupleTableSlot *ExecWindowAgg(WindowAggState *node); extern void ExecEndWindowAgg(WindowAggState *node); extern void ExecReScanWindowAgg(WindowAggState *node); -#endif /* NODEWINDOWAGG_H */ +#endif /* NODEWINDOWAGG_H */ diff --git a/src/include/executor/nodeWorktablescan.h b/src/include/executor/nodeWorktablescan.h index 7790ca2e1b..c222d9f6b4 100644 --- a/src/include/executor/nodeWorktablescan.h +++ b/src/include/executor/nodeWorktablescan.h @@ -21,4 +21,4 @@ extern TupleTableSlot *ExecWorkTableScan(WorkTableScanState *node); extern void ExecEndWorkTableScan(WorkTableScanState *node); extern void ExecReScanWorkTableScan(WorkTableScanState *node); -#endif /* NODEWORKTABLESCAN_H */ +#endif /* NODEWORKTABLESCAN_H */ diff --git a/src/include/executor/spi.h b/src/include/executor/spi.h index c22b3ed5d6..6bbef72cc1 100644 --- a/src/include/executor/spi.h +++ b/src/include/executor/spi.h @@ -163,4 +163,4 @@ extern void AtEOSubXact_SPI(bool isCommit, SubTransactionId mySubid); extern int SPI_execute_direct(const char *src, char *nodename); #endif -#endif /* SPI_H */ +#endif /* SPI_H */ diff --git a/src/include/executor/spi_priv.h b/src/include/executor/spi_priv.h index 49aa7c94e7..ba7fb98875 100644 --- a/src/include/executor/spi_priv.h +++ b/src/include/executor/spi_priv.h @@ -31,7 +31,7 @@ typedef struct MemoryContext procCxt; /* procedure context */ MemoryContext execCxt; /* executor context */ MemoryContext savedcxt; /* context of SPI_connect's caller */ - SubTransactionId connectSubid; /* ID of connecting subtransaction */ + SubTransactionId connectSubid; /* ID of connecting subtransaction */ QueryEnvironment *queryEnv; /* query environment setup for SPI level */ } _SPI_connection; @@ -88,4 +88,4 @@ typedef struct _SPI_plan void *parserSetupArg; } _SPI_plan; -#endif /* SPI_PRIV_H */ +#endif /* SPI_PRIV_H */ diff --git a/src/include/executor/tablefunc.h b/src/include/executor/tablefunc.h index 22ca916eb2..a24a555b75 100644 --- a/src/include/executor/tablefunc.h +++ b/src/include/executor/tablefunc.h @@ -54,14 +54,14 @@ typedef struct TableFuncRoutine void (*InitOpaque) (struct TableFuncScanState *state, int natts); void (*SetDocument) (struct TableFuncScanState *state, Datum value); void (*SetNamespace) (struct TableFuncScanState *state, char *name, - char *uri); + char *uri); void (*SetRowFilter) (struct TableFuncScanState *state, char *path); void (*SetColumnFilter) (struct TableFuncScanState *state, - char *path, int colnum); + char *path, int colnum); bool (*FetchRow) (struct TableFuncScanState *state); Datum (*GetValue) (struct TableFuncScanState *state, int colnum, - Oid typid, int32 typmod, bool *isnull); + Oid typid, int32 typmod, bool *isnull); void (*DestroyOpaque) (struct TableFuncScanState *state); } TableFuncRoutine; -#endif /* _TABLEFUNC_H */ +#endif /* _TABLEFUNC_H */ diff --git a/src/include/executor/tqueue.h b/src/include/executor/tqueue.h index 892eec812e..a717ac6184 100644 --- a/src/include/executor/tqueue.h +++ b/src/include/executor/tqueue.h @@ -30,4 +30,4 @@ extern void DestroyTupleQueueReader(TupleQueueReader *reader); extern HeapTuple TupleQueueReaderNext(TupleQueueReader *reader, bool nowait, bool *done); -#endif /* TQUEUE_H */ +#endif /* TQUEUE_H */ diff --git a/src/include/executor/tstoreReceiver.h b/src/include/executor/tstoreReceiver.h index cd15e27821..ac4de3a663 100644 --- a/src/include/executor/tstoreReceiver.h +++ b/src/include/executor/tstoreReceiver.h @@ -26,4 +26,4 @@ extern void SetTuplestoreDestReceiverParams(DestReceiver *self, MemoryContext tContext, bool detoast); -#endif /* TSTORE_RECEIVER_H */ +#endif /* TSTORE_RECEIVER_H */ diff --git a/src/include/executor/tuptable.h b/src/include/executor/tuptable.h index efdb6fee5a..a1db5eb54b 100644 --- a/src/include/executor/tuptable.h +++ b/src/include/executor/tuptable.h @@ -116,7 +116,7 @@ typedef struct TupleTableSlot NodeTag type; bool tts_isempty; /* true = slot is empty */ bool tts_shouldFree; /* should pfree tts_tuple? */ - bool tts_shouldFreeMin; /* should pfree tts_mintuple? */ + bool tts_shouldFreeMin; /* should pfree tts_mintuple? */ bool tts_slow; /* saved state for slot_deform_tuple */ HeapTuple tts_tuple; /* physical tuple, or NULL if virtual */ #ifdef PGXC @@ -186,4 +186,4 @@ extern void slot_getallattrs(TupleTableSlot *slot); extern void slot_getsomeattrs(TupleTableSlot *slot, int attnum); extern bool slot_attisnull(TupleTableSlot *slot, int attnum); -#endif /* TUPTABLE_H */ +#endif /* TUPTABLE_H */ diff --git a/src/include/fe_utils/mbprint.h b/src/include/fe_utils/mbprint.h index 56626f631b..e3cfaf3ddd 100644 --- a/src/include/fe_utils/mbprint.h +++ b/src/include/fe_utils/mbprint.h @@ -22,8 +22,8 @@ struct lineptr extern unsigned char *mbvalidate(unsigned char *pwcs, int encoding); extern int pg_wcswidth(const char *pwcs, size_t len, int encoding); extern void pg_wcsformat(const unsigned char *pwcs, size_t len, int encoding, - struct lineptr * lines, int count); + struct lineptr *lines, int count); extern void pg_wcssize(const unsigned char *pwcs, size_t len, int encoding, int *width, int *height, int *format_size); -#endif /* MBPRINT_H */ +#endif /* MBPRINT_H */ diff --git a/src/include/fe_utils/print.h b/src/include/fe_utils/print.h index d89b6febcb..36b89e7d57 100644 --- a/src/include/fe_utils/print.h +++ b/src/include/fe_utils/print.h @@ -67,7 +67,7 @@ typedef struct printTextFormat { /* A complete line style */ const char *name; /* for display purposes */ - printTextLineFormat lrule[4]; /* indexed by enum printTextRule */ + printTextLineFormat lrule[4]; /* indexed by enum printTextRule */ const char *midvrule_nl; /* vertical line for continue after newline */ const char *midvrule_wrap; /* vertical line for wrapped data */ const char *midvrule_blank; /* vertical line for blank data */ @@ -77,8 +77,8 @@ typedef struct printTextFormat const char *nl_right; /* right mark for newline */ const char *wrap_left; /* left mark after wrapped data */ const char *wrap_right; /* right mark for wrapped data */ - bool wrap_right_border; /* use right-hand border for wrap - * marks when border=0? */ + bool wrap_right_border; /* use right-hand border for wrap marks + * when border=0? */ } printTextFormat; typedef enum unicode_linestyle @@ -96,14 +96,14 @@ struct separator typedef struct printTableOpt { enum printFormat format; /* see enum above */ - unsigned short int expanded;/* expanded/vertical output (if supported by - * output format); 0=no, 1=yes, 2=auto */ + unsigned short int expanded; /* expanded/vertical output (if supported + * by output format); 0=no, 1=yes, 2=auto */ unsigned short int border; /* Print a border around the table. 0=none, * 1=dividing lines, 2=full */ unsigned short int pager; /* use pager for output (if to stdout and * stdout is a tty) 0=off 1=on 2=always */ - int pager_min_lines;/* don't use pager unless there are at least - * this many lines */ + int pager_min_lines; /* don't use pager unless there are at + * least this many lines */ bool tuples_only; /* don't output headers, row counts, etc. */ bool start_table; /* print start decoration, eg <table> */ bool stop_table; /* print stop decoration, eg </table> */ @@ -166,9 +166,9 @@ typedef struct printQueryOpt char *nullPrint; /* how to print null entities */ char *title; /* override title */ char **footers; /* override footer (default is "(xx rows)") */ - bool translate_header; /* do gettext on column headers */ - const bool *translate_columns; /* translate_columns[i-1] => do - * gettext on col i */ + bool translate_header; /* do gettext on column headers */ + const bool *translate_columns; /* translate_columns[i-1] => do gettext on + * col i */ int n_translate_columns; /* length of translate_columns[] */ } printQueryOpt; @@ -212,4 +212,4 @@ extern void setDecimalLocale(void); extern const printTextFormat *get_line_style(const printTableOpt *opt); extern void refresh_utf8format(const printTableOpt *opt); -#endif /* PRINT_H */ +#endif /* PRINT_H */ diff --git a/src/include/fe_utils/psqlscan.h b/src/include/fe_utils/psqlscan.h index e9c8143925..c199a2917e 100644 --- a/src/include/fe_utils/psqlscan.h +++ b/src/include/fe_utils/psqlscan.h @@ -63,7 +63,7 @@ typedef struct PsqlScanCallbacks /* Fetch value of a variable, as a free'able string; NULL if unknown */ /* This pointer can be NULL if no variable substitution is wanted */ char *(*get_variable) (const char *varname, PsqlScanQuoteType quote, - void *passthrough); + void *passthrough); /* Print an error message someplace appropriate */ /* (very old gcc versions don't support attributes on function pointers) */ #if defined(__GNUC__) && __GNUC__ < 4 @@ -94,4 +94,4 @@ extern void psql_scan_reselect_sql_lexer(PsqlScanState state); extern bool psql_scan_in_quote(PsqlScanState state); -#endif /* PSQLSCAN_H */ +#endif /* PSQLSCAN_H */ diff --git a/src/include/fe_utils/psqlscan_int.h b/src/include/fe_utils/psqlscan_int.h index af62f5ebdf..c70ff29f4e 100644 --- a/src/include/fe_utils/psqlscan_int.h +++ b/src/include/fe_utils/psqlscan_int.h @@ -143,4 +143,4 @@ extern void psqlscan_escape_variable(PsqlScanState state, const char *txt, int len, PsqlScanQuoteType quote); -#endif /* PSQLSCAN_INT_H */ +#endif /* PSQLSCAN_INT_H */ diff --git a/src/include/fe_utils/simple_list.h b/src/include/fe_utils/simple_list.h index b63f5dc061..97bb34f191 100644 --- a/src/include/fe_utils/simple_list.h +++ b/src/include/fe_utils/simple_list.h @@ -34,7 +34,7 @@ typedef struct SimpleStringListCell struct SimpleStringListCell *next; bool touched; /* true, when this string was searched and * touched */ - char val[FLEXIBLE_ARRAY_MEMBER]; /* null-terminated string here */ + char val[FLEXIBLE_ARRAY_MEMBER]; /* null-terminated string here */ } SimpleStringListCell; typedef struct SimpleStringList @@ -52,4 +52,4 @@ extern bool simple_string_list_member(SimpleStringList *list, const char *val); extern const char *simple_string_list_not_touched(SimpleStringList *list); -#endif /* SIMPLE_LIST_H */ +#endif /* SIMPLE_LIST_H */ diff --git a/src/include/fe_utils/string_utils.h b/src/include/fe_utils/string_utils.h index c68234335e..bc6b87d6f1 100644 --- a/src/include/fe_utils/string_utils.h +++ b/src/include/fe_utils/string_utils.h @@ -57,4 +57,4 @@ extern bool processSQLNamePattern(PGconn *conn, PQExpBuffer buf, const char *schemavar, const char *namevar, const char *altnamevar, const char *visibilityrule); -#endif /* STRING_UTILS_H */ +#endif /* STRING_UTILS_H */ diff --git a/src/include/fmgr.h b/src/include/fmgr.h index cfb7b7774d..0216965bfc 100644 --- a/src/include/fmgr.h +++ b/src/include/fmgr.h @@ -82,7 +82,7 @@ typedef struct FunctionCallInfoData Oid fncollation; /* collation for function to use */ bool isnull; /* function must set true if result is NULL */ short nargs; /* # arguments actually passed */ - Datum arg[FUNC_MAX_ARGS]; /* Arguments passed to function */ + Datum arg[FUNC_MAX_ARGS]; /* Arguments passed to function */ bool argnull[FUNC_MAX_ARGS]; /* T if arg[i] is actually NULL */ } FunctionCallInfoData; @@ -196,11 +196,11 @@ extern void fmgr_info_copy(FmgrInfo *dstinfo, FmgrInfo *srcinfo, * Note: it'd be nice if these could be macros, but I see no way to do that * without evaluating the arguments multiple times, which is NOT acceptable. */ -extern struct varlena *pg_detoast_datum(struct varlena * datum); -extern struct varlena *pg_detoast_datum_copy(struct varlena * datum); -extern struct varlena *pg_detoast_datum_slice(struct varlena * datum, +extern struct varlena *pg_detoast_datum(struct varlena *datum); +extern struct varlena *pg_detoast_datum_copy(struct varlena *datum); +extern struct varlena *pg_detoast_datum_slice(struct varlena *datum, int32 first, int32 count); -extern struct varlena *pg_detoast_datum_packed(struct varlena * datum); +extern struct varlena *pg_detoast_datum_packed(struct varlena *datum); #define PG_DETOAST_DATUM(datum) \ pg_detoast_datum((struct varlena *) DatumGetPointer(datum)) @@ -690,8 +690,8 @@ extern void RestoreLibraryState(char *start_address); */ /* AggCheckCallContext can return one of the following codes, or 0: */ -#define AGG_CONTEXT_AGGREGATE 1 /* regular aggregate */ -#define AGG_CONTEXT_WINDOW 2 /* window function */ +#define AGG_CONTEXT_AGGREGATE 1 /* regular aggregate */ +#define AGG_CONTEXT_WINDOW 2 /* window function */ extern int AggCheckCallContext(FunctionCallInfo fcinfo, MemoryContext *aggcontext); @@ -720,7 +720,7 @@ typedef enum FmgrHookEventType typedef bool (*needs_fmgr_hook_type) (Oid fn_oid); typedef void (*fmgr_hook_type) (FmgrHookEventType event, - FmgrInfo *flinfo, Datum *arg); + FmgrInfo *flinfo, Datum *arg); extern PGDLLIMPORT needs_fmgr_hook_type needs_fmgr_hook; extern PGDLLIMPORT fmgr_hook_type fmgr_hook; @@ -743,4 +743,4 @@ extern PGDLLIMPORT fmgr_hook_type fmgr_hook; */ extern char *fmgr(Oid procedureId,...); -#endif /* FMGR_H */ +#endif /* FMGR_H */ diff --git a/src/include/foreign/fdwapi.h b/src/include/foreign/fdwapi.h index 6ca44f734f..e391f20fb8 100644 --- a/src/include/foreign/fdwapi.h +++ b/src/include/foreign/fdwapi.h @@ -25,136 +25,136 @@ struct ExplainState; */ typedef void (*GetForeignRelSize_function) (PlannerInfo *root, - RelOptInfo *baserel, - Oid foreigntableid); + RelOptInfo *baserel, + Oid foreigntableid); typedef void (*GetForeignPaths_function) (PlannerInfo *root, - RelOptInfo *baserel, - Oid foreigntableid); + RelOptInfo *baserel, + Oid foreigntableid); typedef ForeignScan *(*GetForeignPlan_function) (PlannerInfo *root, - RelOptInfo *baserel, - Oid foreigntableid, - ForeignPath *best_path, - List *tlist, - List *scan_clauses, - Plan *outer_plan); + RelOptInfo *baserel, + Oid foreigntableid, + ForeignPath *best_path, + List *tlist, + List *scan_clauses, + Plan *outer_plan); typedef void (*BeginForeignScan_function) (ForeignScanState *node, - int eflags); + int eflags); typedef TupleTableSlot *(*IterateForeignScan_function) (ForeignScanState *node); typedef bool (*RecheckForeignScan_function) (ForeignScanState *node, - TupleTableSlot *slot); + TupleTableSlot *slot); typedef void (*ReScanForeignScan_function) (ForeignScanState *node); typedef void (*EndForeignScan_function) (ForeignScanState *node); typedef void (*GetForeignJoinPaths_function) (PlannerInfo *root, - RelOptInfo *joinrel, - RelOptInfo *outerrel, - RelOptInfo *innerrel, - JoinType jointype, - JoinPathExtraData *extra); + RelOptInfo *joinrel, + RelOptInfo *outerrel, + RelOptInfo *innerrel, + JoinType jointype, + JoinPathExtraData *extra); typedef void (*GetForeignUpperPaths_function) (PlannerInfo *root, - UpperRelationKind stage, - RelOptInfo *input_rel, - RelOptInfo *output_rel); + UpperRelationKind stage, + RelOptInfo *input_rel, + RelOptInfo *output_rel); typedef void (*AddForeignUpdateTargets_function) (Query *parsetree, - RangeTblEntry *target_rte, - Relation target_relation); + RangeTblEntry *target_rte, + Relation target_relation); typedef List *(*PlanForeignModify_function) (PlannerInfo *root, - ModifyTable *plan, - Index resultRelation, - int subplan_index); + ModifyTable *plan, + Index resultRelation, + int subplan_index); typedef void (*BeginForeignModify_function) (ModifyTableState *mtstate, - ResultRelInfo *rinfo, - List *fdw_private, - int subplan_index, - int eflags); + ResultRelInfo *rinfo, + List *fdw_private, + int subplan_index, + int eflags); typedef TupleTableSlot *(*ExecForeignInsert_function) (EState *estate, - ResultRelInfo *rinfo, - TupleTableSlot *slot, - TupleTableSlot *planSlot); + ResultRelInfo *rinfo, + TupleTableSlot *slot, + TupleTableSlot *planSlot); typedef TupleTableSlot *(*ExecForeignUpdate_function) (EState *estate, - ResultRelInfo *rinfo, - TupleTableSlot *slot, - TupleTableSlot *planSlot); + ResultRelInfo *rinfo, + TupleTableSlot *slot, + TupleTableSlot *planSlot); typedef TupleTableSlot *(*ExecForeignDelete_function) (EState *estate, - ResultRelInfo *rinfo, - TupleTableSlot *slot, - TupleTableSlot *planSlot); + ResultRelInfo *rinfo, + TupleTableSlot *slot, + TupleTableSlot *planSlot); typedef void (*EndForeignModify_function) (EState *estate, - ResultRelInfo *rinfo); + ResultRelInfo *rinfo); typedef int (*IsForeignRelUpdatable_function) (Relation rel); typedef bool (*PlanDirectModify_function) (PlannerInfo *root, - ModifyTable *plan, - Index resultRelation, - int subplan_index); + ModifyTable *plan, + Index resultRelation, + int subplan_index); typedef void (*BeginDirectModify_function) (ForeignScanState *node, - int eflags); + int eflags); typedef TupleTableSlot *(*IterateDirectModify_function) (ForeignScanState *node); typedef void (*EndDirectModify_function) (ForeignScanState *node); typedef RowMarkType (*GetForeignRowMarkType_function) (RangeTblEntry *rte, - LockClauseStrength strength); + LockClauseStrength strength); typedef HeapTuple (*RefetchForeignRow_function) (EState *estate, - ExecRowMark *erm, - Datum rowid, - bool *updated); + ExecRowMark *erm, + Datum rowid, + bool *updated); typedef void (*ExplainForeignScan_function) (ForeignScanState *node, - struct ExplainState *es); + struct ExplainState *es); typedef void (*ExplainForeignModify_function) (ModifyTableState *mtstate, - ResultRelInfo *rinfo, - List *fdw_private, - int subplan_index, - struct ExplainState *es); + ResultRelInfo *rinfo, + List *fdw_private, + int subplan_index, + struct ExplainState *es); typedef void (*ExplainDirectModify_function) (ForeignScanState *node, - struct ExplainState *es); + struct ExplainState *es); typedef int (*AcquireSampleRowsFunc) (Relation relation, int elevel, - HeapTuple *rows, int targrows, - double *totalrows, - double *totaldeadrows); + HeapTuple *rows, int targrows, + double *totalrows, + double *totaldeadrows); typedef bool (*AnalyzeForeignTable_function) (Relation relation, - AcquireSampleRowsFunc *func, - BlockNumber *totalpages); + AcquireSampleRowsFunc *func, + BlockNumber *totalpages); typedef List *(*ImportForeignSchema_function) (ImportForeignSchemaStmt *stmt, - Oid serverOid); + Oid serverOid); typedef Size (*EstimateDSMForeignScan_function) (ForeignScanState *node, - ParallelContext *pcxt); + ParallelContext *pcxt); typedef void (*InitializeDSMForeignScan_function) (ForeignScanState *node, - ParallelContext *pcxt, - void *coordinate); + ParallelContext *pcxt, + void *coordinate); typedef void (*InitializeWorkerForeignScan_function) (ForeignScanState *node, - shm_toc *toc, - void *coordinate); + shm_toc *toc, + void *coordinate); typedef void (*ShutdownForeignScan_function) (ForeignScanState *node); typedef bool (*IsForeignScanParallelSafe_function) (PlannerInfo *root, - RelOptInfo *rel, - RangeTblEntry *rte); + RelOptInfo *rel, + RangeTblEntry *rte); /* * FdwRoutine is the struct returned by a foreign-data wrapper's handler @@ -239,4 +239,4 @@ extern bool IsImportableForeignTable(const char *tablename, ImportForeignSchemaStmt *stmt); extern Path *GetExistingLocalJoinPath(RelOptInfo *joinrel); -#endif /* FDWAPI_H */ +#endif /* FDWAPI_H */ diff --git a/src/include/foreign/foreign.h b/src/include/foreign/foreign.h index 446a071239..2f4c569d1d 100644 --- a/src/include/foreign/foreign.h +++ b/src/include/foreign/foreign.h @@ -82,4 +82,4 @@ extern List *GetForeignColumnOptions(Oid relid, AttrNumber attnum); extern Oid get_foreign_data_wrapper_oid(const char *fdwname, bool missing_ok); extern Oid get_foreign_server_oid(const char *servername, bool missing_ok); -#endif /* FOREIGN_H */ +#endif /* FOREIGN_H */ diff --git a/src/include/funcapi.h b/src/include/funcapi.h index 30e66b6335..951af2aad3 100644 --- a/src/include/funcapi.h +++ b/src/include/funcapi.h @@ -315,4 +315,4 @@ extern void end_MultiFuncCall(PG_FUNCTION_ARGS, FuncCallContext *funcctx); PG_RETURN_NULL(); \ } while (0) -#endif /* FUNCAPI_H */ +#endif /* FUNCAPI_H */ diff --git a/src/include/getaddrinfo.h b/src/include/getaddrinfo.h index c5595142a5..3dcfc1fa25 100644 --- a/src/include/getaddrinfo.h +++ b/src/include/getaddrinfo.h @@ -55,8 +55,8 @@ #define EAI_NONAME WSAHOST_NOT_FOUND #define EAI_SERVICE WSATYPE_NOT_FOUND #define EAI_SOCKTYPE WSAESOCKTNOSUPPORT -#endif /* !WIN32 */ -#endif /* !EAI_FAIL */ +#endif /* !WIN32 */ +#endif /* !EAI_FAIL */ #ifndef AI_PASSIVE #define AI_PASSIVE 0x0001 @@ -124,7 +124,7 @@ struct addrinfo struct addrinfo *ai_next; }; #endif -#endif /* HAVE_STRUCT_ADDRINFO */ +#endif /* HAVE_STRUCT_ADDRINFO */ #ifndef HAVE_GETADDRINFO @@ -151,12 +151,12 @@ struct addrinfo #define getnameinfo pg_getnameinfo extern int getaddrinfo(const char *node, const char *service, - const struct addrinfo * hints, struct addrinfo ** res); -extern void freeaddrinfo(struct addrinfo * res); + const struct addrinfo *hints, struct addrinfo **res); +extern void freeaddrinfo(struct addrinfo *res); extern const char *gai_strerror(int errcode); -extern int getnameinfo(const struct sockaddr * sa, int salen, +extern int getnameinfo(const struct sockaddr *sa, int salen, char *node, int nodelen, char *service, int servicelen, int flags); -#endif /* HAVE_GETADDRINFO */ +#endif /* HAVE_GETADDRINFO */ -#endif /* GETADDRINFO_H */ +#endif /* GETADDRINFO_H */ diff --git a/src/include/getopt_long.h b/src/include/getopt_long.h index a16c5f9b14..c55d45348a 100644 --- a/src/include/getopt_long.h +++ b/src/include/getopt_long.h @@ -30,7 +30,7 @@ struct option extern int getopt_long(int argc, char *const argv[], const char *optstring, - const struct option * longopts, int *longindex); + const struct option *longopts, int *longindex); #endif -#endif /* GETOPT_LONG_H */ +#endif /* GETOPT_LONG_H */ diff --git a/src/include/lib/binaryheap.h b/src/include/lib/binaryheap.h index a4bbb390ea..da7504bd55 100644 --- a/src/include/lib/binaryheap.h +++ b/src/include/lib/binaryheap.h @@ -51,4 +51,4 @@ extern void binaryheap_replace_first(binaryheap *heap, Datum d); #define binaryheap_empty(h) ((h)->bh_size == 0) -#endif /* BINARYHEAP_H */ +#endif /* BINARYHEAP_H */ diff --git a/src/include/lib/bipartite_match.h b/src/include/lib/bipartite_match.h index d662b3821e..8f580bbd97 100644 --- a/src/include/lib/bipartite_match.h +++ b/src/include/lib/bipartite_match.h @@ -43,4 +43,4 @@ extern BipartiteMatchState *BipartiteMatch(int u_size, int v_size, short **adjac extern void BipartiteMatchFree(BipartiteMatchState *state); -#endif /* BIPARTITE_MATCH_H */ +#endif /* BIPARTITE_MATCH_H */ diff --git a/src/include/lib/hyperloglog.h b/src/include/lib/hyperloglog.h index dd40fe9b00..7a249cd252 100644 --- a/src/include/lib/hyperloglog.h +++ b/src/include/lib/hyperloglog.h @@ -65,4 +65,4 @@ extern void addHyperLogLog(hyperLogLogState *cState, uint32 hash); extern double estimateHyperLogLog(hyperLogLogState *cState); extern void freeHyperLogLog(hyperLogLogState *cState); -#endif /* HYPERLOGLOG_H */ +#endif /* HYPERLOGLOG_H */ diff --git a/src/include/lib/ilist.h b/src/include/lib/ilist.h index 8a44c90c4f..e5ac5c218a 100644 --- a/src/include/lib/ilist.h +++ b/src/include/lib/ilist.h @@ -266,7 +266,7 @@ extern void slist_check(slist_head *head); */ #define dlist_check(head) ((void) (head)) #define slist_check(head) ((void) (head)) -#endif /* ILIST_DEBUG */ +#endif /* ILIST_DEBUG */ /* doubly linked list implementation */ @@ -724,4 +724,4 @@ slist_delete_current(slist_mutable_iter *iter) (iter).cur = (iter).next, \ (iter).next = (iter).next ? (iter).next->next : NULL) -#endif /* ILIST_H */ +#endif /* ILIST_H */ diff --git a/src/include/lib/knapsack.h b/src/include/lib/knapsack.h index 8d1e6d0aa0..4485738e2a 100644 --- a/src/include/lib/knapsack.h +++ b/src/include/lib/knapsack.h @@ -14,4 +14,4 @@ extern Bitmapset *DiscreteKnapsack(int max_weight, int num_items, int *item_weights, double *item_values); -#endif /* KNAPSACK_H */ +#endif /* KNAPSACK_H */ diff --git a/src/include/lib/pairingheap.h b/src/include/lib/pairingheap.h index 9ee90befe5..e3a75f51f7 100644 --- a/src/include/lib/pairingheap.h +++ b/src/include/lib/pairingheap.h @@ -58,8 +58,8 @@ typedef struct pairingheap_node * and >0 iff a > b. For a min-heap, the conditions are reversed. */ typedef int (*pairingheap_comparator) (const pairingheap_node *a, - const pairingheap_node *b, - void *arg); + const pairingheap_node *b, + void *arg); /* * A pairing heap. @@ -85,7 +85,7 @@ extern void pairingheap_remove(pairingheap *heap, pairingheap_node *node); #ifdef PAIRINGHEAP_DEBUG extern char *pairingheap_dump(pairingheap *heap, - void (*dumpfunc) (pairingheap_node *node, StringInfo buf, void *opaque), + void (*dumpfunc) (pairingheap_node *node, StringInfo buf, void *opaque), void *opaque); #endif @@ -99,4 +99,4 @@ extern char *pairingheap_dump(pairingheap *heap, #define pairingheap_is_singular(h) \ ((h)->ph_root && (h)->ph_root->first_child == NULL) -#endif /* PAIRINGHEAP_H */ +#endif /* PAIRINGHEAP_H */ diff --git a/src/include/lib/rbtree.h b/src/include/lib/rbtree.h index 7e2b7ae71b..a7183bb0b4 100644 --- a/src/include/lib/rbtree.h +++ b/src/include/lib/rbtree.h @@ -79,4 +79,4 @@ extern void rb_begin_iterate(RBTree *rb, RBOrderControl ctrl, RBTreeIterator *iter); extern RBNode *rb_iterate(RBTreeIterator *iter); -#endif /* RBTREE_H */ +#endif /* RBTREE_H */ diff --git a/src/include/lib/simplehash.h b/src/include/lib/simplehash.h index 47dd0bc4ee..c5af5b96a7 100644 --- a/src/include/lib/simplehash.h +++ b/src/include/lib/simplehash.h @@ -121,7 +121,7 @@ typedef struct SH_TYPE /* user defined data, useful for callbacks */ void *private_data; -} SH_TYPE; +} SH_TYPE; typedef enum SH_STATUS { @@ -134,22 +134,22 @@ typedef struct SH_ITERATOR uint32 cur; /* current element */ uint32 end; bool done; /* iterator exhausted? */ -} SH_ITERATOR; +} SH_ITERATOR; /* externally visible function prototypes */ -SH_SCOPE SH_TYPE *SH_CREATE(MemoryContext ctx, uint32 nelements, +SH_SCOPE SH_TYPE *SH_CREATE(MemoryContext ctx, uint32 nelements, void *private_data); SH_SCOPE void SH_DESTROY(SH_TYPE * tb); SH_SCOPE void SH_GROW(SH_TYPE * tb, uint32 newsize); -SH_SCOPE SH_ELEMENT_TYPE *SH_INSERT(SH_TYPE * tb, SH_KEY_TYPE key, bool *found); -SH_SCOPE SH_ELEMENT_TYPE *SH_LOOKUP(SH_TYPE * tb, SH_KEY_TYPE key); +SH_SCOPE SH_ELEMENT_TYPE *SH_INSERT(SH_TYPE * tb, SH_KEY_TYPE key, bool *found); +SH_SCOPE SH_ELEMENT_TYPE *SH_LOOKUP(SH_TYPE * tb, SH_KEY_TYPE key); SH_SCOPE bool SH_DELETE(SH_TYPE * tb, SH_KEY_TYPE key); SH_SCOPE void SH_START_ITERATE(SH_TYPE * tb, SH_ITERATOR * iter); SH_SCOPE void SH_START_ITERATE_AT(SH_TYPE * tb, SH_ITERATOR * iter, uint32 at); -SH_SCOPE SH_ELEMENT_TYPE *SH_ITERATE(SH_TYPE * tb, SH_ITERATOR * iter); +SH_SCOPE SH_ELEMENT_TYPE *SH_ITERATE(SH_TYPE * tb, SH_ITERATOR * iter); SH_SCOPE void SH_STAT(SH_TYPE * tb); -#endif /* SH_DECLARE */ +#endif /* SH_DECLARE */ /* generate implementation of the hash table */ @@ -324,7 +324,7 @@ SH_FREE(SH_TYPE * type, void *pointer) * Memory other than for the array of elements will still be allocated from * the passed-in context. */ -SH_SCOPE SH_TYPE * +SH_SCOPE SH_TYPE * SH_CREATE(MemoryContext ctx, uint32 nelements, void *private_data) { SH_TYPE *tb; @@ -470,7 +470,7 @@ SH_GROW(SH_TYPE * tb, uint32 newsize) * already exists, false otherwise. Returns the hash-table entry in either * case. */ -SH_SCOPE SH_ELEMENT_TYPE * +SH_SCOPE SH_ELEMENT_TYPE * SH_INSERT(SH_TYPE * tb, SH_KEY_TYPE key, bool *found) { uint32 hash = SH_HASH_KEY(tb, key); @@ -634,7 +634,7 @@ restart: /* * Lookup up entry in hash table. Returns NULL if key not present. */ -SH_SCOPE SH_ELEMENT_TYPE * +SH_SCOPE SH_ELEMENT_TYPE * SH_LOOKUP(SH_TYPE * tb, SH_KEY_TYPE key) { uint32 hash = SH_HASH_KEY(tb, key); @@ -788,7 +788,7 @@ SH_START_ITERATE_AT(SH_TYPE * tb, SH_ITERATOR * iter, uint32 at) * Iterate backwards, that allows the current element to be deleted, even * if there are backward shifts. */ - iter->cur = at & tb->sizemask; /* ensure at is within a valid range */ + iter->cur = at & tb->sizemask; /* ensure at is within a valid range */ iter->end = iter->cur; iter->done = false; } @@ -803,7 +803,7 @@ SH_START_ITERATE_AT(SH_TYPE * tb, SH_ITERATOR * iter, uint32 at) * deletions), but if so, there's neither a guarantee that all nodes are * visited at least once, nor a guarantee that a node is visited at most once. */ -SH_SCOPE SH_ELEMENT_TYPE * +SH_SCOPE SH_ELEMENT_TYPE * SH_ITERATE(SH_TYPE * tb, SH_ITERATOR * iter) { while (!iter->done) @@ -899,10 +899,10 @@ SH_STAT(SH_TYPE * tb) total_collisions, max_collisions, avg_collisions); } -#endif /* SH_DEFINE */ +#endif /* SH_DEFINE */ -/* undefine external paramters, so next hash table can be defined */ +/* undefine external parameters, so next hash table can be defined */ #undef SH_PREFIX #undef SH_KEY_TYPE #undef SH_KEY diff --git a/src/include/lib/stringinfo.h b/src/include/lib/stringinfo.h index 316c196565..9694ea3f21 100644 --- a/src/include/lib/stringinfo.h +++ b/src/include/lib/stringinfo.h @@ -149,4 +149,4 @@ extern void appendBinaryStringInfo(StringInfo str, */ extern void enlargeStringInfo(StringInfo str, int needed); -#endif /* STRINGINFO_H */ +#endif /* STRINGINFO_H */ diff --git a/src/include/libpq/auth.h b/src/include/libpq/auth.h index 601dc5d71a..871cc03add 100644 --- a/src/include/libpq/auth.h +++ b/src/include/libpq/auth.h @@ -26,4 +26,4 @@ extern void ClientAuthentication(Port *port); typedef void (*ClientAuthentication_hook_type) (Port *, int); extern PGDLLIMPORT ClientAuthentication_hook_type ClientAuthentication_hook; -#endif /* AUTH_H */ +#endif /* AUTH_H */ diff --git a/src/include/libpq/be-fsstubs.h b/src/include/libpq/be-fsstubs.h index 641124cd21..96bcaa0f08 100644 --- a/src/include/libpq/be-fsstubs.h +++ b/src/include/libpq/be-fsstubs.h @@ -34,4 +34,4 @@ extern void AtEOXact_LargeObject(bool isCommit); extern void AtEOSubXact_LargeObject(bool isCommit, SubTransactionId mySubid, SubTransactionId parentSubid); -#endif /* BE_FSSTUBS_H */ +#endif /* BE_FSSTUBS_H */ diff --git a/src/include/libpq/hba.h b/src/include/libpq/hba.h index f28b860877..07d92d4f9f 100644 --- a/src/include/libpq/hba.h +++ b/src/include/libpq/hba.h @@ -120,4 +120,4 @@ extern int check_usermap(const char *usermap_name, bool case_sensitive); extern bool pg_isblank(const char c); -#endif /* HBA_H */ +#endif /* HBA_H */ diff --git a/src/include/libpq/ifaddr.h b/src/include/libpq/ifaddr.h index 5f6f48598f..be19ff8823 100644 --- a/src/include/libpq/ifaddr.h +++ b/src/include/libpq/ifaddr.h @@ -14,17 +14,17 @@ #include "libpq/pqcomm.h" /* pgrminclude ignore */ -typedef void (*PgIfAddrCallback) (struct sockaddr * addr, - struct sockaddr * netmask, - void *cb_data); +typedef void (*PgIfAddrCallback) (struct sockaddr *addr, + struct sockaddr *netmask, + void *cb_data); -extern int pg_range_sockaddr(const struct sockaddr_storage * addr, - const struct sockaddr_storage * netaddr, - const struct sockaddr_storage * netmask); +extern int pg_range_sockaddr(const struct sockaddr_storage *addr, + const struct sockaddr_storage *netaddr, + const struct sockaddr_storage *netmask); -extern int pg_sockaddr_cidr_mask(struct sockaddr_storage * mask, +extern int pg_sockaddr_cidr_mask(struct sockaddr_storage *mask, char *numbits, int family); extern int pg_foreach_ifaddr(PgIfAddrCallback callback, void *cb_data); -#endif /* IFADDR_H */ +#endif /* IFADDR_H */ diff --git a/src/include/libpq/libpq-be.h b/src/include/libpq/libpq-be.h index ed4ecea816..8b1b84a5ae 100644 --- a/src/include/libpq/libpq-be.h +++ b/src/include/libpq/libpq-be.h @@ -32,7 +32,7 @@ #include <gssapi.h> #else #include <gssapi/gssapi.h> -#endif /* HAVE_GSSAPI_H */ +#endif /* HAVE_GSSAPI_H */ /* * GSSAPI brings in headers that set a lot of things in the global namespace on win32, * that doesn't match the msvc build. It gives a bunch of compiler warnings that we ignore, @@ -41,7 +41,7 @@ #ifdef _MSC_VER #undef HAVE_GETADDRINFO #endif -#endif /* ENABLE_GSS */ +#endif /* ENABLE_GSS */ #ifdef ENABLE_SSPI #define SECURITY_WIN32 @@ -61,7 +61,7 @@ typedef struct int length; } gss_buffer_desc; #endif -#endif /* ENABLE_SSPI */ +#endif /* ENABLE_SSPI */ #include "datatype/timestamp.h" #include "libpq/hba.h" @@ -120,10 +120,10 @@ typedef struct Port SockAddr laddr; /* local addr (postmaster) */ SockAddr raddr; /* remote addr (client) */ char *remote_host; /* name (or ip addr) of remote host */ - char *remote_hostname;/* name (not ip addr) of remote host, if - * available */ + char *remote_hostname; /* name (not ip addr) of remote host, if + * available */ int remote_hostname_resolv; /* see above */ - int remote_hostname_errcode; /* see above */ + int remote_hostname_errcode; /* see above */ char *remote_port; /* text rep of remote port */ CAC_state canAcceptConnections; /* postmaster connection status */ @@ -147,7 +147,7 @@ typedef struct Port * but since it gets used by elog.c in the same way as database_name and * other members of this struct, we may as well keep it here. */ - TimestampTz SessionStartTime; /* backend start time */ + TimestampTz SessionStartTime; /* backend start time */ /* * TCP keepalive settings. @@ -222,4 +222,4 @@ extern int pq_setkeepalivesidle(int idle, Port *port); extern int pq_setkeepalivesinterval(int interval, Port *port); extern int pq_setkeepalivescount(int count, Port *port); -#endif /* LIBPQ_BE_H */ +#endif /* LIBPQ_BE_H */ diff --git a/src/include/libpq/libpq-fs.h b/src/include/libpq/libpq-fs.h index afe32706f4..ce4b2a1892 100644 --- a/src/include/libpq/libpq-fs.h +++ b/src/include/libpq/libpq-fs.h @@ -21,4 +21,4 @@ #define INV_WRITE 0x00020000 #define INV_READ 0x00040000 -#endif /* LIBPQ_FS_H */ +#endif /* LIBPQ_FS_H */ diff --git a/src/include/libpq/libpq.h b/src/include/libpq/libpq.h index d4885a5e28..78851b1060 100644 --- a/src/include/libpq/libpq.h +++ b/src/include/libpq/libpq.h @@ -99,4 +99,4 @@ extern char *SSLCipherSuites; extern char *SSLECDHCurve; extern bool SSLPreferServerCiphers; -#endif /* LIBPQ_H */ +#endif /* LIBPQ_H */ diff --git a/src/include/libpq/pqcomm.h b/src/include/libpq/pqcomm.h index b6de569c5c..10c7434c41 100644 --- a/src/include/libpq/pqcomm.h +++ b/src/include/libpq/pqcomm.h @@ -57,7 +57,7 @@ struct sockaddr_storage #define ss_len ss_stuff.sa.sa_len #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_LEN 1 #endif -#endif /* HAVE_STRUCT_SOCKADDR_STORAGE */ +#endif /* HAVE_STRUCT_SOCKADDR_STORAGE */ typedef struct { @@ -133,19 +133,19 @@ typedef uint32 PacketLen; #define SM_DATABASE 64 #define SM_USER 32 /* We append database name if db_user_namespace true. */ -#define SM_DATABASE_USER (SM_DATABASE+SM_USER+1) /* +1 for @ */ +#define SM_DATABASE_USER (SM_DATABASE+SM_USER+1) /* +1 for @ */ #define SM_OPTIONS 64 #define SM_UNUSED 64 #define SM_TTY 64 typedef struct StartupPacket { - ProtocolVersion protoVersion; /* Protocol version */ + ProtocolVersion protoVersion; /* Protocol version */ char database[SM_DATABASE]; /* Database name */ /* Db_user_namespace appends dbname */ char user[SM_USER]; /* User name */ char options[SM_OPTIONS]; /* Optional additional args */ - char unused[SM_UNUSED]; /* Unused */ + char unused[SM_UNUSED]; /* Unused */ char tty[SM_TTY]; /* Tty for debug output */ } StartupPacket; @@ -192,7 +192,7 @@ typedef uint32 AuthRequest; typedef struct CancelRequestPacket { /* Note that each field is stored in network byte order! */ - MsgType cancelRequestCode; /* code to identify a cancel request */ + MsgType cancelRequestCode; /* code to identify a cancel request */ uint32 backendPID; /* PID of client's backend */ uint32 cancelAuthCode; /* secret key to authorize cancel */ } CancelRequestPacket; @@ -204,4 +204,4 @@ typedef struct CancelRequestPacket */ #define NEGOTIATE_SSL_CODE PG_PROTOCOL(1234,5679) -#endif /* PQCOMM_H */ +#endif /* PQCOMM_H */ diff --git a/src/include/libpq/pqformat.h b/src/include/libpq/pqformat.h index 4df87ec8a2..32112547a0 100644 --- a/src/include/libpq/pqformat.h +++ b/src/include/libpq/pqformat.h @@ -47,4 +47,4 @@ extern const char *pq_getmsgstring(StringInfo msg); extern const char *pq_getmsgrawstring(StringInfo msg); extern void pq_getmsgend(StringInfo msg); -#endif /* PQFORMAT_H */ +#endif /* PQFORMAT_H */ diff --git a/src/include/libpq/pqmq.h b/src/include/libpq/pqmq.h index e356bd60f4..86436d6753 100644 --- a/src/include/libpq/pqmq.h +++ b/src/include/libpq/pqmq.h @@ -21,4 +21,4 @@ extern void pq_set_parallel_master(pid_t pid, BackendId backend_id); extern void pq_parse_errornotice(StringInfo str, ErrorData *edata); -#endif /* PQMQ_H */ +#endif /* PQMQ_H */ diff --git a/src/include/libpq/pqsignal.h b/src/include/libpq/pqsignal.h index a9dbce49d1..af4e61ba4d 100644 --- a/src/include/libpq/pqsignal.h +++ b/src/include/libpq/pqsignal.h @@ -28,7 +28,7 @@ extern int pqsigsetmask(int mask); #define sigfillset(set) (*(set) = ~0) #define sigaddset(set, signum) (*(set) |= (sigmask(signum))) #define sigdelset(set, signum) (*(set) &= ~(sigmask(signum))) -#endif /* WIN32 */ +#endif /* WIN32 */ extern sigset_t UnBlockSig, BlockSig, @@ -36,4 +36,4 @@ extern sigset_t UnBlockSig, extern void pqinitmask(void); -#endif /* PQSIGNAL_H */ +#endif /* PQSIGNAL_H */ diff --git a/src/include/libpq/scram.h b/src/include/libpq/scram.h index 14b48af12f..0166e1945d 100644 --- a/src/include/libpq/scram.h +++ b/src/include/libpq/scram.h @@ -31,4 +31,4 @@ extern char *pg_be_scram_build_verifier(const char *password); extern bool scram_verify_plain_password(const char *username, const char *password, const char *verifier); -#endif /* PG_SCRAM_H */ +#endif /* PG_SCRAM_H */ diff --git a/src/include/mb/pg_wchar.h b/src/include/mb/pg_wchar.h index 737ab1c713..d57ef017cb 100644 --- a/src/include/mb/pg_wchar.h +++ b/src/include/mb/pg_wchar.h @@ -133,10 +133,12 @@ typedef unsigned int pg_wchar; #define LC_JISX0212 0x94 /* Japanese Kanji (JIS X 0212) */ #define LC_CNS11643_1 0x95 /* CNS 11643-1992 Plane 1 */ #define LC_CNS11643_2 0x96 /* CNS 11643-1992 Plane 2 */ -#define LC_JISX0213_1 0x97/* Japanese Kanji (JIS X 0213 Plane 1) (not - * supported) */ -#define LC_BIG5_1 0x98 /* Plane 1 Chinese traditional (not supported) */ -#define LC_BIG5_2 0x99 /* Plane 1 Chinese traditional (not supported) */ +#define LC_JISX0213_1 0x97 /* Japanese Kanji (JIS X 0213 Plane 1) + * (not supported) */ +#define LC_BIG5_1 0x98 /* Plane 1 Chinese traditional (not + * supported) */ +#define LC_BIG5_2 0x99 /* Plane 1 Chinese traditional (not + * supported) */ /* Is a leading byte for "official" multibyte encodings? */ #define IS_LC2(c) ((unsigned char)(c) >= 0x90 && (unsigned char)(c) <= 0x99) @@ -168,44 +170,44 @@ typedef unsigned int pg_wchar; /* * Charset IDs for private single byte encodings (0xa0-0xef) */ -#define LC_SISHENG 0xa0/* Chinese SiSheng characters for - * PinYin/ZhuYin (not supported) */ -#define LC_IPA 0xa1/* IPA (International Phonetic Association) - * (not supported) */ -#define LC_VISCII_LOWER 0xa2/* Vietnamese VISCII1.1 lower-case (not - * supported) */ -#define LC_VISCII_UPPER 0xa3/* Vietnamese VISCII1.1 upper-case (not - * supported) */ +#define LC_SISHENG 0xa0 /* Chinese SiSheng characters for + * PinYin/ZhuYin (not supported) */ +#define LC_IPA 0xa1 /* IPA (International Phonetic + * Association) (not supported) */ +#define LC_VISCII_LOWER 0xa2 /* Vietnamese VISCII1.1 lower-case (not + * supported) */ +#define LC_VISCII_UPPER 0xa3 /* Vietnamese VISCII1.1 upper-case (not + * supported) */ #define LC_ARABIC_DIGIT 0xa4 /* Arabic digit (not supported) */ #define LC_ARABIC_1_COLUMN 0xa5 /* Arabic 1-column (not supported) */ #define LC_ASCII_RIGHT_TO_LEFT 0xa6 /* ASCII (left half of ISO8859-1) with * right-to-left direction (not * supported) */ -#define LC_LAO 0xa7/* Lao characters (ISO10646 0E80..0EDF) (not - * supported) */ +#define LC_LAO 0xa7 /* Lao characters (ISO10646 0E80..0EDF) + * (not supported) */ #define LC_ARABIC_2_COLUMN 0xa8 /* Arabic 1-column (not supported) */ /* * Charset IDs for private multibyte encodings (0xf0-0xff) */ -#define LC_INDIAN_1_COLUMN 0xf0/* Indian charset for 1-column width glyphs - * (not supported) */ -#define LC_TIBETAN_1_COLUMN 0xf1/* Tibetan 1-column width glyphs (not - * supported) */ -#define LC_UNICODE_SUBSET_2 0xf2/* Unicode characters of the range - * U+2500..U+33FF. (not supported) */ -#define LC_UNICODE_SUBSET_3 0xf3/* Unicode characters of the range - * U+E000..U+FFFF. (not supported) */ -#define LC_UNICODE_SUBSET 0xf4/* Unicode characters of the range - * U+0100..U+24FF. (not supported) */ +#define LC_INDIAN_1_COLUMN 0xf0 /* Indian charset for 1-column width + * glyphs (not supported) */ +#define LC_TIBETAN_1_COLUMN 0xf1 /* Tibetan 1-column width glyphs (not + * supported) */ +#define LC_UNICODE_SUBSET_2 0xf2 /* Unicode characters of the range + * U+2500..U+33FF. (not supported) */ +#define LC_UNICODE_SUBSET_3 0xf3 /* Unicode characters of the range + * U+E000..U+FFFF. (not supported) */ +#define LC_UNICODE_SUBSET 0xf4 /* Unicode characters of the range + * U+0100..U+24FF. (not supported) */ #define LC_ETHIOPIC 0xf5 /* Ethiopic characters (not supported) */ #define LC_CNS11643_3 0xf6 /* CNS 11643-1992 Plane 3 */ #define LC_CNS11643_4 0xf7 /* CNS 11643-1992 Plane 4 */ #define LC_CNS11643_5 0xf8 /* CNS 11643-1992 Plane 5 */ #define LC_CNS11643_6 0xf9 /* CNS 11643-1992 Plane 6 */ #define LC_CNS11643_7 0xfa /* CNS 11643-1992 Plane 7 */ -#define LC_INDIAN_2_COLUMN 0xfb/* Indian charset for 2-column width glyphs - * (not supported) */ +#define LC_INDIAN_2_COLUMN 0xfb /* Indian charset for 2-column width + * glyphs (not supported) */ #define LC_TIBETAN 0xfc /* Tibetan (not supported) */ /* #define FREE 0xfd free (unused) */ /* #define FREE 0xfe free (unused) */ @@ -342,12 +344,12 @@ extern const char *get_encoding_name_for_icu(int encoding); * pg_wchar stuff */ typedef int (*mb2wchar_with_len_converter) (const unsigned char *from, - pg_wchar *to, - int len); + pg_wchar *to, + int len); typedef int (*wchar2mb_with_len_converter) (const pg_wchar *from, - unsigned char *to, - int len); + unsigned char *to, + int len); typedef int (*mblen_converter) (const unsigned char *mbstr); @@ -359,12 +361,12 @@ typedef int (*mbverifier) (const unsigned char *mbstr, int len); typedef struct { - mb2wchar_with_len_converter mb2wchar_with_len; /* convert a multibyte - * string to a wchar */ - wchar2mb_with_len_converter wchar2mb_with_len; /* convert a wchar - * string to a multibyte */ + mb2wchar_with_len_converter mb2wchar_with_len; /* convert a multibyte + * string to a wchar */ + wchar2mb_with_len_converter wchar2mb_with_len; /* convert a wchar string + * to a multibyte */ mblen_converter mblen; /* get byte length of a char */ - mbdisplaylen_converter dsplen; /* get display width of a char */ + mbdisplaylen_converter dsplen; /* get display width of a char */ mbverifier mbverify; /* verify multibyte sequence */ int maxmblen; /* max bytes for a char in this encoding */ } pg_wchar_tbl; @@ -597,7 +599,7 @@ extern void check_encoding_conversion_args(int src_encoding, extern void report_invalid_encoding(int encoding, const char *mbstr, int len) pg_attribute_noreturn(); extern void report_untranslatable_char(int src_encoding, int dest_encoding, - const char *mbstr, int len) pg_attribute_noreturn(); + const char *mbstr, int len) pg_attribute_noreturn(); extern void local2local(const unsigned char *l, unsigned char *p, int len, int src_encoding, int dest_encoding, const unsigned char *tab); @@ -620,4 +622,4 @@ extern bool pg_utf8_islegal(const unsigned char *source, int length); extern WCHAR *pgwin32_message_to_UTF16(const char *str, int len, int *utf16len); #endif -#endif /* PG_WCHAR_H */ +#endif /* PG_WCHAR_H */ diff --git a/src/include/miscadmin.h b/src/include/miscadmin.h index 8ac73dd403..58feafd919 100644 --- a/src/include/miscadmin.h +++ b/src/include/miscadmin.h @@ -112,7 +112,7 @@ do { \ if (InterruptPending) \ ProcessInterrupts(); \ } while(0) -#endif /* WIN32 */ +#endif /* WIN32 */ #define HOLD_INTERRUPTS() (InterruptHoldoffCount++) @@ -487,4 +487,4 @@ extern bool has_rolreplication(Oid roleid); extern bool BackupInProgress(void); extern void CancelBackup(void); -#endif /* MISCADMIN_H */ +#endif /* MISCADMIN_H */ diff --git a/src/include/nodes/bitmapset.h b/src/include/nodes/bitmapset.h index f381bedd44..28641e20d4 100644 --- a/src/include/nodes/bitmapset.h +++ b/src/include/nodes/bitmapset.h @@ -105,4 +105,4 @@ extern uint32 bms_hash_value(const Bitmapset *a); extern int bms_any_member(Bitmapset *a); #endif -#endif /* BITMAPSET_H */ +#endif /* BITMAPSET_H */ diff --git a/src/include/nodes/execnodes.h b/src/include/nodes/execnodes.h index 2bc126dabe..86f379c126 100644 --- a/src/include/nodes/execnodes.h +++ b/src/include/nodes/execnodes.h @@ -45,8 +45,8 @@ struct ExprContext; struct ExprEvalStep; /* avoid including execExpr.h everywhere */ typedef Datum (*ExprStateEvalFunc) (struct ExprState *expression, - struct ExprContext *econtext, - bool *isNull); + struct ExprContext *econtext, + bool *isNull); /* Bits in ExprState->flags (see also execExpr.h for private flag bits): */ /* expression is for use with ExecQual() */ @@ -140,8 +140,8 @@ typedef struct IndexInfo List *ii_Predicate; /* list of Expr */ ExprState *ii_PredicateState; Oid *ii_ExclusionOps; /* array with one entry per column */ - Oid *ii_ExclusionProcs; /* array with one entry per column */ - uint16 *ii_ExclusionStrats; /* array with one entry per column */ + Oid *ii_ExclusionProcs; /* array with one entry per column */ + uint16 *ii_ExclusionStrats; /* array with one entry per column */ Oid *ii_UniqueOps; /* array with one entry per column */ Oid *ii_UniqueProcs; /* array with one entry per column */ uint16 *ii_UniqueStrats; /* array with one entry per column */ @@ -205,7 +205,7 @@ typedef struct ExprContext MemoryContext ecxt_per_tuple_memory; /* Values to substitute for Param nodes in expression */ - ParamExecData *ecxt_param_exec_vals; /* for PARAM_EXEC params */ + ParamExecData *ecxt_param_exec_vals; /* for PARAM_EXEC params */ ParamListInfo ecxt_param_list_info; /* for other param types */ /* @@ -251,7 +251,7 @@ typedef enum { SFRM_ValuePerCall = 0x01, /* one value returned per call */ SFRM_Materialize = 0x02, /* result set instantiated in Tuplestore */ - SFRM_Materialize_Random = 0x04, /* Tuplestore needs randomAccess */ + SFRM_Materialize_Random = 0x04, /* Tuplestore needs randomAccess */ SFRM_Materialize_Preferred = 0x08 /* caller prefers Tuplestore */ } SetFunctionReturnMode; @@ -338,61 +338,81 @@ typedef struct JunkFilter AttrNumber jf_junkAttNo; } JunkFilter; -/* ---------------- - * ResultRelInfo information - * - * Whenever we update an existing relation, we have to - * update indices on the relation, and perhaps also fire triggers. - * The ResultRelInfo class is used to hold all the information needed - * about a result relation, including indices.. -cim 10/15/89 - * - * RangeTableIndex result relation's range table index - * RelationDesc relation descriptor for result relation - * NumIndices # of indices existing on result relation - * IndexRelationDescs array of relation descriptors for indices - * IndexRelationInfo array of key/attr info for indices - * TrigDesc triggers to be fired, if any - * TrigFunctions cached lookup info for trigger functions - * TrigWhenExprs array of trigger WHEN expr states - * TrigInstrument optional runtime measurements for triggers - * FdwRoutine FDW callback functions, if foreign table - * FdwState available to save private state of FDW - * usesFdwDirectModify true when modifying foreign table directly - * WithCheckOptions list of WithCheckOption's to be checked - * WithCheckOptionExprs list of WithCheckOption expr states - * ConstraintExprs array of constraint-checking expr states - * junkFilter for removing junk attributes from tuples - * projectReturning for computing a RETURNING list - * onConflictSetProj for computing ON CONFLICT DO UPDATE SET - * onConflictSetWhere list of ON CONFLICT DO UPDATE exprs (qual) - * PartitionCheck partition check expression - * PartitionCheckExpr partition check expression state - * ---------------- +/* + * ResultRelInfo + * + * Whenever we update an existing relation, we have to update indexes on the + * relation, and perhaps also fire triggers. ResultRelInfo holds all the + * information needed about a result relation, including indexes. */ typedef struct ResultRelInfo { NodeTag type; + + /* result relation's range table index */ Index ri_RangeTableIndex; + + /* relation descriptor for result relation */ Relation ri_RelationDesc; + + /* # of indices existing on result relation */ int ri_NumIndices; + + /* array of relation descriptors for indices */ RelationPtr ri_IndexRelationDescs; + + /* array of key/attr info for indices */ IndexInfo **ri_IndexRelationInfo; + + /* triggers to be fired, if any */ TriggerDesc *ri_TrigDesc; + + /* cached lookup info for trigger functions */ FmgrInfo *ri_TrigFunctions; + + /* array of trigger WHEN expr states */ ExprState **ri_TrigWhenExprs; + + /* optional runtime measurements for triggers */ Instrumentation *ri_TrigInstrument; + + /* FDW callback functions, if foreign table */ struct FdwRoutine *ri_FdwRoutine; + + /* available to save private state of FDW */ void *ri_FdwState; + + /* true when modifying foreign table directly */ bool ri_usesFdwDirectModify; + + /* list of WithCheckOption's to be checked */ List *ri_WithCheckOptions; + + /* list of WithCheckOption expr states */ List *ri_WithCheckOptionExprs; + + /* array of constraint-checking expr states */ ExprState **ri_ConstraintExprs; + + /* for removing junk attributes from tuples */ JunkFilter *ri_junkFilter; + + /* for computing a RETURNING list */ ProjectionInfo *ri_projectReturning; + + /* for computing ON CONFLICT DO UPDATE SET */ ProjectionInfo *ri_onConflictSetProj; + + /* list of ON CONFLICT DO UPDATE exprs (qual) */ ExprState *ri_onConflictSetWhere; + + /* partition check expression */ List *ri_PartitionCheck; + + /* partition check expression state */ ExprState *ri_PartitionCheckExpr; + + /* relation descriptor for root partitioned table */ Relation ri_PartitionRoot; } ResultRelInfo; @@ -421,13 +441,8 @@ typedef struct EState /* Info about target table(s) for insert/update/delete queries: */ ResultRelInfo *es_result_relations; /* array of ResultRelInfos */ - int es_num_result_relations; /* length of array */ - ResultRelInfo *es_result_relation_info; /* currently active array elt */ -#ifdef PGXC -#ifndef PGXC - struct PlanState *es_result_remoterel; /* currently active remote rel */ -#endif -#endif + int es_num_result_relations; /* length of array */ + ResultRelInfo *es_result_relation_info; /* currently active array elt */ /* * Info about the target partitioned target table root(s) for @@ -440,16 +455,16 @@ typedef struct EState int es_num_root_result_relations; /* length of the array */ /* Stuff used for firing triggers: */ - List *es_trig_target_relations; /* trigger-only ResultRelInfos */ + List *es_trig_target_relations; /* trigger-only ResultRelInfos */ TupleTableSlot *es_trig_tuple_slot; /* for trigger output tuples */ - TupleTableSlot *es_trig_oldtup_slot; /* for TriggerEnabled */ - TupleTableSlot *es_trig_newtup_slot; /* for TriggerEnabled */ + TupleTableSlot *es_trig_oldtup_slot; /* for TriggerEnabled */ + TupleTableSlot *es_trig_newtup_slot; /* for TriggerEnabled */ /* Parameter info: */ ParamListInfo es_param_list_info; /* values of external params */ ParamExecData *es_param_exec_vals; /* values of internal params */ - QueryEnvironment *es_queryEnv; /* query environment */ + QueryEnvironment *es_queryEnv; /* query environment */ /* Other working state: */ MemoryContext es_query_cxt; /* per-query context in which EState lives */ @@ -467,9 +482,9 @@ typedef struct EState List *es_exprcontexts; /* List of ExprContexts within EState */ - List *es_subplanstates; /* List of PlanState for SubPlans */ + List *es_subplanstates; /* List of PlanState for SubPlans */ - List *es_auxmodifytables; /* List of secondary ModifyTableStates */ + List *es_auxmodifytables; /* List of secondary ModifyTableStates */ /* * this ExprContext is for per-output-tuple operations, such as constraint @@ -576,7 +591,7 @@ typedef struct TupleHashEntryData uint32 hash; /* hash value (cached) */ } TupleHashEntryData; -/* define paramters necessary to generate the tuple hash table interface */ +/* define parameters necessary to generate the tuple hash table interface */ #define SH_PREFIX tuplehash #define SH_ELEMENT_TYPE TupleHashEntryData #define SH_KEY_TYPE MinimalTuple @@ -600,7 +615,7 @@ typedef struct TupleHashTableData FmgrInfo *in_hash_funcs; /* hash functions for input datatype(s) */ FmgrInfo *cur_eq_funcs; /* equality functions for input vs. table */ uint32 hash_iv; /* hash-function IV */ -} TupleHashTableData; +} TupleHashTableData; typedef tuplehash_iterator TupleHashIterator; @@ -698,8 +713,7 @@ typedef struct SetExprState * output. If so, it's stored here. */ TupleDesc funcResultDesc; - bool funcReturnsTuple; /* valid when funcResultDesc isn't - * NULL */ + bool funcReturnsTuple; /* valid when funcResultDesc isn't NULL */ /* * Remember whether the function is declared to return a set. This is set @@ -791,7 +805,7 @@ typedef enum DomainConstraintType typedef struct DomainConstraintState { NodeTag type; - DomainConstraintType constrainttype; /* constraint type */ + DomainConstraintType constrainttype; /* constraint type */ char *name; /* name of constraint (for error msgs) */ Expr *check_expr; /* for CHECK, a boolean expression */ ExprState *check_exprstate; /* check_expr's eval state, or NULL */ @@ -914,7 +928,7 @@ typedef struct ProjectSetState Node **elems; /* array of expression states */ ExprDoneCond *elemdone; /* array of per-SRF is-done states */ int nelems; /* length of elemdone[] array */ - bool pending_srf_tuples; /* still evaluating srfs in tlist? */ + bool pending_srf_tuples; /* still evaluating srfs in tlist? */ } ProjectSetState; /* ---------------- @@ -933,26 +947,24 @@ typedef struct ModifyTableState #endif int mt_nplans; /* number of plans in the array */ int mt_whichplan; /* which one is being executed (0..n-1) */ - ResultRelInfo *resultRelInfo; /* per-subplan target relations */ + ResultRelInfo *resultRelInfo; /* per-subplan target relations */ ResultRelInfo *rootResultRelInfo; /* root target relation (partitioned * table root) */ List **mt_arowmarks; /* per-subplan ExecAuxRowMark lists */ EPQState mt_epqstate; /* for evaluating EvalPlanQual rechecks */ bool fireBSTriggers; /* do we need to fire stmt triggers? */ - OnConflictAction mt_onconflict; /* ON CONFLICT type */ - List *mt_arbiterindexes; /* unique index OIDs to arbitrate - * taking alt path */ + OnConflictAction mt_onconflict; /* ON CONFLICT type */ + List *mt_arbiterindexes; /* unique index OIDs to arbitrate taking + * alt path */ TupleTableSlot *mt_existing; /* slot to store existing target tuple in */ - List *mt_excludedtlist; /* the excluded pseudo relation's - * tlist */ - TupleTableSlot *mt_conflproj; /* CONFLICT ... SET ... projection - * target */ + List *mt_excludedtlist; /* the excluded pseudo relation's tlist */ + TupleTableSlot *mt_conflproj; /* CONFLICT ... SET ... projection target */ struct PartitionDispatchData **mt_partition_dispatch_info; /* Tuple-routing support info */ int mt_num_dispatch; /* Number of entries in the above array */ - int mt_num_partitions; /* Number of members in the following - * arrays */ - ResultRelInfo *mt_partitions; /* Per partition result relation */ + int mt_num_partitions; /* Number of members in the following + * arrays */ + ResultRelInfo *mt_partitions; /* Per partition result relation */ TupleConversionMap **mt_partition_tupconv_maps; /* Per partition tuple conversion map */ TupleTableSlot *mt_partition_tuple_slot; @@ -1091,7 +1103,7 @@ typedef struct SampleScanState List *args; /* expr states for TABLESAMPLE params */ ExprState *repeatable; /* expr state for REPEATABLE expr */ /* use struct pointer to avoid including tsmapi.h here */ - struct TsmRoutine *tsmroutine; /* descriptor for tablesample method */ + struct TsmRoutine *tsmroutine; /* descriptor for tablesample method */ void *tsm_state; /* tablesample method can keep state here */ bool use_bulkread; /* use bulkread buffer access strategy? */ bool use_pagemode; /* use page-at-a-time visibility checking? */ @@ -1390,8 +1402,7 @@ typedef struct FunctionScanState bool simple; int64 ordinal; int nfuncs; - struct FunctionScanPerFuncState *funcstates; /* array of length - * nfuncs */ + struct FunctionScanPerFuncState *funcstates; /* array of length nfuncs */ MemoryContext argcontext; } FunctionScanState; @@ -1438,7 +1449,7 @@ typedef struct TableFuncScanState List *ns_uris; /* list of states of namespace uri exprs */ Bitmapset *notnulls; /* nullability flag for each output column */ void *opaque; /* table builder private space */ - const struct TableFuncRoutine *routine; /* table builder methods */ + const struct TableFuncRoutine *routine; /* table builder methods */ FmgrInfo *in_functions; /* input function for each column */ Oid *typioparams; /* typioparam for each column */ int64 ordinal; /* row number to be output next */ @@ -1510,7 +1521,7 @@ typedef struct WorkTableScanState typedef struct ForeignScanState { ScanState ss; /* its first field is NodeTag */ - ExprState *fdw_recheck_quals; /* original quals not in ss.ps.qual */ + ExprState *fdw_recheck_quals; /* original quals not in ss.ps.qual */ Size pscan_len; /* size of parallel coordination information */ /* use struct pointer to avoid including fdwapi.h here */ struct FdwRoutine *fdwroutine; @@ -1660,9 +1671,9 @@ typedef struct HashJoinState { JoinState js; /* its first field is NodeTag */ ExprState *hashclauses; - List *hj_OuterHashKeys; /* list of ExprState nodes */ - List *hj_InnerHashKeys; /* list of ExprState nodes */ - List *hj_HashOperators; /* list of operator OIDs */ + List *hj_OuterHashKeys; /* list of ExprState nodes */ + List *hj_InnerHashKeys; /* list of ExprState nodes */ + List *hj_HashOperators; /* list of operator OIDs */ HashJoinTable hj_HashTable; uint32 hj_CurHashValue; int hj_CurBucketNo; @@ -1764,14 +1775,13 @@ typedef struct AggState ExprContext **aggcontexts; /* econtexts for long-lived data (per GS) */ ExprContext *tmpcontext; /* econtext for input expressions */ ExprContext *curaggcontext; /* currently active aggcontext */ - AggStatePerTrans curpertrans; /* currently active trans state */ + AggStatePerTrans curpertrans; /* currently active trans state */ bool input_done; /* indicates end of input */ bool agg_done; /* indicates completion of Agg scan */ int projected_set; /* The last projected grouping set */ int current_set; /* The current grouping set being evaluated */ Bitmapset *grouped_cols; /* grouped cols in current projection */ - List *all_grouped_cols; /* list of all grouped cols in DESC - * order */ + List *all_grouped_cols; /* list of all grouped cols in DESC order */ /* These fields are for grouping set phase data */ int maxsets; /* The max number of sets in any phase */ AggStatePerPhase phases; /* array of all phases */ @@ -1820,15 +1830,14 @@ typedef struct WindowAggState int64 frameheadpos; /* current frame head position */ int64 frametailpos; /* current frame tail position */ /* use struct pointer to avoid including windowapi.h here */ - struct WindowObjectData *agg_winobj; /* winobj for aggregate - * fetches */ + struct WindowObjectData *agg_winobj; /* winobj for aggregate fetches */ int64 aggregatedbase; /* start row for current aggregates */ int64 aggregatedupto; /* rows before this one are aggregated */ int frameOptions; /* frame_clause options, see WindowDef */ ExprState *startOffset; /* expression for starting bound offset */ ExprState *endOffset; /* expression for ending bound offset */ - Datum startOffsetValue; /* result of startOffset evaluation */ + Datum startOffsetValue; /* result of startOffset evaluation */ Datum endOffsetValue; /* result of endOffset evaluation */ MemoryContext partcontext; /* context for partition-lifespan data */ @@ -1838,15 +1847,14 @@ typedef struct WindowAggState bool all_first; /* true if the scan is starting */ bool all_done; /* true if the scan is finished */ - bool partition_spooled; /* true if all tuples in current - * partition have been spooled into - * tuplestore */ - bool more_partitions;/* true if there's more partitions after this - * one */ - bool framehead_valid;/* true if frameheadpos is known up to date - * for current row */ - bool frametail_valid;/* true if frametailpos is known up to date - * for current row */ + bool partition_spooled; /* true if all tuples in current partition + * have been spooled into tuplestore */ + bool more_partitions; /* true if there's more partitions after + * this one */ + bool framehead_valid; /* true if frameheadpos is known up to + * date for current row */ + bool frametail_valid; /* true if frametailpos is known up to + * date for current row */ TupleTableSlot *first_part_slot; /* first tuple of current or next * partition */ @@ -1920,8 +1928,7 @@ typedef struct GatherMergeState bool need_to_scan_locally; int gm_nkeys; SortSupport gm_sortkeys; /* array of length ms_nkeys */ - struct GMReaderTupleBuffer *gm_tuple_buffers; /* tuple buffer per - * reader */ + struct GMReaderTupleBuffer *gm_tuple_buffers; /* tuple buffer per reader */ } GatherMergeState; /* ---------------- @@ -2017,4 +2024,4 @@ typedef struct LimitState TupleTableSlot *subSlot; /* tuple last obtained from subplan */ } LimitState; -#endif /* EXECNODES_H */ +#endif /* EXECNODES_H */ diff --git a/src/include/nodes/extensible.h b/src/include/nodes/extensible.h index 0b02cc18e9..7325bf536a 100644 --- a/src/include/nodes/extensible.h +++ b/src/include/nodes/extensible.h @@ -62,11 +62,11 @@ typedef struct ExtensibleNodeMethods const char *extnodename; Size node_size; void (*nodeCopy) (struct ExtensibleNode *newnode, - const struct ExtensibleNode *oldnode); + const struct ExtensibleNode *oldnode); bool (*nodeEqual) (const struct ExtensibleNode *a, - const struct ExtensibleNode *b); + const struct ExtensibleNode *b); void (*nodeOut) (struct StringInfoData *str, - const struct ExtensibleNode *node); + const struct ExtensibleNode *node); void (*nodeRead) (struct ExtensibleNode *node); } ExtensibleNodeMethods; @@ -91,12 +91,12 @@ typedef struct CustomPathMethods /* Convert Path to a Plan */ struct Plan *(*PlanCustomPath) (PlannerInfo *root, - RelOptInfo *rel, - struct CustomPath *best_path, - List *tlist, - List *clauses, - List *custom_plans); -} CustomPathMethods; + RelOptInfo *rel, + struct CustomPath *best_path, + List *tlist, + List *clauses, + List *custom_plans); +} CustomPathMethods; /* * Custom scan. Here again, there's not much to do: we need to be able to @@ -120,8 +120,8 @@ typedef struct CustomExecMethods /* Required executor methods */ void (*BeginCustomScan) (CustomScanState *node, - EState *estate, - int eflags); + EState *estate, + int eflags); TupleTableSlot *(*ExecCustomScan) (CustomScanState *node); void (*EndCustomScan) (CustomScanState *node); void (*ReScanCustomScan) (CustomScanState *node); @@ -132,23 +132,23 @@ typedef struct CustomExecMethods /* Optional methods: needed if parallel execution is supported */ Size (*EstimateDSMCustomScan) (CustomScanState *node, - ParallelContext *pcxt); + ParallelContext *pcxt); void (*InitializeDSMCustomScan) (CustomScanState *node, - ParallelContext *pcxt, - void *coordinate); + ParallelContext *pcxt, + void *coordinate); void (*InitializeWorkerCustomScan) (CustomScanState *node, - shm_toc *toc, - void *coordinate); + shm_toc *toc, + void *coordinate); void (*ShutdownCustomScan) (CustomScanState *node); /* Optional: print additional information in EXPLAIN */ void (*ExplainCustomScan) (CustomScanState *node, - List *ancestors, - ExplainState *es); + List *ancestors, + ExplainState *es); } CustomExecMethods; extern void RegisterCustomScanMethods(const CustomScanMethods *methods); extern const CustomScanMethods *GetCustomScanMethods(const char *CustomName, bool missing_ok); -#endif /* EXTENSIBLE_H */ +#endif /* EXTENSIBLE_H */ diff --git a/src/include/nodes/lockoptions.h b/src/include/nodes/lockoptions.h index 4f8affd930..e0981dac6f 100644 --- a/src/include/nodes/lockoptions.h +++ b/src/include/nodes/lockoptions.h @@ -43,4 +43,4 @@ typedef enum LockWaitPolicy LockWaitError } LockWaitPolicy; -#endif /* LOCKOPTIONS_H */ +#endif /* LOCKOPTIONS_H */ diff --git a/src/include/nodes/makefuncs.h b/src/include/nodes/makefuncs.h index 53ea6598c8..46a79b1817 100644 --- a/src/include/nodes/makefuncs.h +++ b/src/include/nodes/makefuncs.h @@ -86,4 +86,4 @@ extern DefElem *makeDefElemExtended(char *nameSpace, char *name, Node *arg, extern GroupingSet *makeGroupingSet(GroupingSetKind kind, List *content, int location); -#endif /* MAKEFUNC_H */ +#endif /* MAKEFUNC_H */ diff --git a/src/include/nodes/memnodes.h b/src/include/nodes/memnodes.h index fe6bc903b3..7a0c6763df 100644 --- a/src/include/nodes/memnodes.h +++ b/src/include/nodes/memnodes.h @@ -63,7 +63,7 @@ typedef struct MemoryContextMethods Size (*get_chunk_space) (MemoryContext context, void *pointer); bool (*is_empty) (MemoryContext context); void (*stats) (MemoryContext context, int level, bool print, - MemoryContextCounters *totals); + MemoryContextCounters *totals); #ifdef MEMORY_CONTEXT_CHECKING void (*check) (MemoryContext context); #endif @@ -75,8 +75,8 @@ typedef struct MemoryContextData NodeTag type; /* identifies exact kind of context */ /* these two fields are placed here to minimize alignment wastage: */ bool isReset; /* T = no space alloced since last reset */ - bool allowInCritSection; /* allow palloc in critical section */ - MemoryContextMethods *methods; /* virtual function table */ + bool allowInCritSection; /* allow palloc in critical section */ + MemoryContextMethods *methods; /* virtual function table */ MemoryContext parent; /* NULL if no parent (toplevel context) */ MemoryContext firstchild; /* head of linked list of children */ MemoryContext prevchild; /* previous child of same parent */ @@ -98,4 +98,4 @@ typedef struct MemoryContextData ((context) != NULL && \ (IsA((context), AllocSetContext) || IsA((context), SlabContext))) -#endif /* MEMNODES_H */ +#endif /* MEMNODES_H */ diff --git a/src/include/nodes/nodeFuncs.h b/src/include/nodes/nodeFuncs.h index b6c9b48ee6..3366983936 100644 --- a/src/include/nodes/nodeFuncs.h +++ b/src/include/nodes/nodeFuncs.h @@ -17,13 +17,13 @@ /* flags bits for query_tree_walker and query_tree_mutator */ -#define QTW_IGNORE_RT_SUBQUERIES 0x01 /* subqueries in rtable */ -#define QTW_IGNORE_CTE_SUBQUERIES 0x02 /* subqueries in cteList */ -#define QTW_IGNORE_RC_SUBQUERIES 0x03 /* both of above */ -#define QTW_IGNORE_JOINALIASES 0x04 /* JOIN alias var lists */ -#define QTW_IGNORE_RANGE_TABLE 0x08 /* skip rangetable entirely */ -#define QTW_EXAMINE_RTES 0x10 /* examine RTEs */ -#define QTW_DONT_COPY_QUERY 0x20 /* do not copy top Query */ +#define QTW_IGNORE_RT_SUBQUERIES 0x01 /* subqueries in rtable */ +#define QTW_IGNORE_CTE_SUBQUERIES 0x02 /* subqueries in cteList */ +#define QTW_IGNORE_RC_SUBQUERIES 0x03 /* both of above */ +#define QTW_IGNORE_JOINALIASES 0x04 /* JOIN alias var lists */ +#define QTW_IGNORE_RANGE_TABLE 0x08 /* skip rangetable entirely */ +#define QTW_EXAMINE_RTES 0x10 /* examine RTEs */ +#define QTW_DONT_COPY_QUERY 0x20 /* do not copy top Query */ /* callback function for check_functions_in_node */ typedef bool (*check_function_callback) (Oid func_id, void *context); @@ -51,30 +51,30 @@ extern bool check_functions_in_node(Node *node, check_function_callback checker, void *context); extern bool expression_tree_walker(Node *node, bool (*walker) (), - void *context); + void *context); extern Node *expression_tree_mutator(Node *node, Node *(*mutator) (), - void *context); + void *context); extern bool query_tree_walker(Query *query, bool (*walker) (), - void *context, int flags); + void *context, int flags); extern Query *query_tree_mutator(Query *query, Node *(*mutator) (), - void *context, int flags); + void *context, int flags); extern bool range_table_walker(List *rtable, bool (*walker) (), - void *context, int flags); + void *context, int flags); extern List *range_table_mutator(List *rtable, Node *(*mutator) (), - void *context, int flags); + void *context, int flags); extern bool query_or_expression_tree_walker(Node *node, bool (*walker) (), - void *context, int flags); + void *context, int flags); extern Node *query_or_expression_tree_mutator(Node *node, Node *(*mutator) (), - void *context, int flags); + void *context, int flags); extern bool raw_expression_tree_walker(Node *node, bool (*walker) (), - void *context); + void *context); struct PlanState; extern bool planstate_tree_walker(struct PlanState *planstate, bool (*walker) (), - void *context); + void *context); -#endif /* NODEFUNCS_H */ +#endif /* NODEFUNCS_H */ diff --git a/src/include/nodes/nodes.h b/src/include/nodes/nodes.h index df93faed90..779947f0f6 100644 --- a/src/include/nodes/nodes.h +++ b/src/include/nodes/nodes.h @@ -596,7 +596,7 @@ extern PGDLLIMPORT Node *newNodeMacroHolder; newNodeMacroHolder->type = (tag), \ newNodeMacroHolder \ ) -#endif /* __GNUC__ */ +#endif /* __GNUC__ */ #define makeNode(_type_) ((_type_ *) newNode(sizeof(_type_),T_##_type_)) @@ -621,7 +621,7 @@ castNodeImpl(NodeTag type, void *ptr) #define castNode(_type_, nodeptr) ((_type_ *) castNodeImpl(T_##_type_, nodeptr)) #else #define castNode(_type_, nodeptr) ((_type_ *) (nodeptr)) -#endif /* USE_ASSERT_CHECKING */ +#endif /* USE_ASSERT_CHECKING */ /* ---------------------------------------------------------------- @@ -665,6 +665,7 @@ extern int16 *readAttrNumberCols(int numCols); * nodes/copyfuncs.c */ extern void *copyObjectImpl(const void *obj); + /* cast result back to argument type, if supported by compiler */ #ifdef HAVE_TYPEOF #define copyObject(obj) ((typeof(obj)) copyObjectImpl(obj)) @@ -857,4 +858,4 @@ typedef enum OnConflictAction ONCONFLICT_UPDATE /* ON CONFLICT ... DO UPDATE */ } OnConflictAction; -#endif /* NODES_H */ +#endif /* NODES_H */ diff --git a/src/include/nodes/params.h b/src/include/nodes/params.h index d9a48191f0..9297c91b4b 100644 --- a/src/include/nodes/params.h +++ b/src/include/nodes/params.h @@ -50,7 +50,7 @@ struct ParseState; * ---------------- */ -#define PARAM_FLAG_CONST 0x0001 /* parameter is constant */ +#define PARAM_FLAG_CONST 0x0001 /* parameter is constant */ typedef struct ParamExternData { @@ -75,7 +75,7 @@ typedef struct ParamListInfoData int numParams; /* number of ParamExternDatas following */ struct Bitmapset *paramMask; /* if non-NULL, can ignore omitted params */ ParamExternData params[FLEXIBLE_ARRAY_MEMBER]; -} ParamListInfoData; +} ParamListInfoData; /* ---------------- @@ -113,4 +113,4 @@ extern Size EstimateParamListSpace(ParamListInfo paramLI); extern void SerializeParamList(ParamListInfo paramLI, char **start_address); extern ParamListInfo RestoreParamList(char **start_address); -#endif /* PARAMS_H */ +#endif /* PARAMS_H */ diff --git a/src/include/nodes/parsenodes.h b/src/include/nodes/parsenodes.h index fb3684eb5c..fb8dbc871b 100644 --- a/src/include/nodes/parsenodes.h +++ b/src/include/nodes/parsenodes.h @@ -172,10 +172,9 @@ typedef struct Query List *constraintDeps; /* a list of pg_constraint OIDs that the query * depends on to be semantically valid */ - List *withCheckOptions; /* a list of WithCheckOption's, which - * are only added during rewrite and - * therefore are not written out as - * part of Query. */ + List *withCheckOptions; /* a list of WithCheckOption's, which are + * only added during rewrite and therefore + * are not written out as part of Query. */ /* * The following two fields identify the portion of the source text string @@ -357,7 +356,7 @@ typedef struct FuncCall List *args; /* the arguments (list of exprs) */ List *agg_order; /* ORDER BY (list of SortBy) */ Node *agg_filter; /* FILTER clause, if any */ - bool agg_within_group; /* ORDER BY appeared in WITHIN GROUP */ + bool agg_within_group; /* ORDER BY appeared in WITHIN GROUP */ bool agg_star; /* argument was really '*' */ bool agg_distinct; /* arguments were labeled DISTINCT */ bool func_variadic; /* last argument was labeled VARIADIC */ @@ -965,13 +964,13 @@ typedef struct RangeTblEntry */ Oid relid; /* OID of the relation */ char relkind; /* relation kind (see pg_class.relkind) */ - struct TableSampleClause *tablesample; /* sampling info, or NULL */ + struct TableSampleClause *tablesample; /* sampling info, or NULL */ /* * Fields valid for a subquery RTE (else NULL): */ Query *subquery; /* the sub-query */ - bool security_barrier; /* is from security_barrier view? */ + bool security_barrier; /* is from security_barrier view? */ /* * Fields valid for a join RTE (else NULL/zero): @@ -1026,11 +1025,11 @@ typedef struct RangeTblEntry * * We need these for CTE RTEs so that the types of self-referential * columns are well-defined. For VALUES RTEs, storing these explicitly - * saves having to re-determine the info by scanning the values_lists. - * For ENRs, we store the types explicitly here (we could get the - * information from the catalogs if 'relid' was supplied, but we'd still - * need these for TupleDesc-based ENRs, so we might as well always store - * the type info here). + * saves having to re-determine the info by scanning the values_lists. For + * ENRs, we store the types explicitly here (we could get the information + * from the catalogs if 'relid' was supplied, but we'd still need these + * for TupleDesc-based ENRs, so we might as well always store the type + * info here). */ List *coltypes; /* OID list of column type OIDs */ List *coltypmods; /* integer list of column typmods */ @@ -1084,7 +1083,7 @@ typedef struct RangeTblFunction List *funccolnames; /* column names (list of String) */ List *funccoltypes; /* OID list of column type OIDs */ List *funccoltypmods; /* integer list of column typmods */ - List *funccolcollations; /* OID list of column collation OIDs */ + List *funccolcollations; /* OID list of column collation OIDs */ /* This is set during planning for use by the executor: */ Bitmapset *funcparams; /* PARAM_EXEC Param IDs affecting this func */ } RangeTblFunction; @@ -1377,7 +1376,7 @@ typedef struct CommonTableExpr List *ctecolnames; /* list of output column names */ List *ctecoltypes; /* OID list of output column type OIDs */ List *ctecoltypmods; /* integer list of output column typmods */ - List *ctecolcollations; /* OID list of column collation OIDs */ + List *ctecolcollations; /* OID list of column collation OIDs */ } CommonTableExpr; /* Convenience macro to get the output tlist of a CTE's query */ @@ -1715,7 +1714,7 @@ typedef enum AlterTableType AT_ReAddConstraint, /* internal to commands/tablecmds.c */ AT_AlterConstraint, /* alter constraint */ AT_ValidateConstraint, /* validate constraint */ - AT_ValidateConstraintRecurse, /* internal to commands/tablecmds.c */ + AT_ValidateConstraintRecurse, /* internal to commands/tablecmds.c */ AT_ProcessedConstraint, /* pre-processed add constraint (local in * parser/parse_utilcmd.c) */ AT_AddIndexConstraint, /* add constraint using existing index */ @@ -1723,7 +1722,7 @@ typedef enum AlterTableType AT_DropConstraintRecurse, /* internal to commands/tablecmds.c */ AT_ReAddComment, /* internal to commands/tablecmds.c */ AT_AlterColumnType, /* alter column type */ - AT_AlterColumnGenericOptions, /* alter column OPTIONS (...) */ + AT_AlterColumnGenericOptions, /* alter column OPTIONS (...) */ AT_ChangeOwner, /* change owner */ AT_ClusterOn, /* CLUSTER ON */ AT_DropCluster, /* SET WITHOUT CLUSTER */ @@ -1882,9 +1881,9 @@ typedef struct ObjectWithArgs NodeTag type; List *objname; /* qualified name of function/operator */ List *objargs; /* list of Typename nodes */ - bool args_unspecified; /* argument list was omitted, so name - * must be unique (note that objargs - * == NIL means zero args) */ + bool args_unspecified; /* argument list was omitted, so name must + * be unique (note that objargs == NIL + * means zero args) */ } ObjectWithArgs; /* @@ -2008,7 +2007,7 @@ typedef struct CreateStmt List *tableElts; /* column definitions (list of ColumnDef) */ List *inhRelations; /* relations to inherit from (list of * inhRelation) */ - PartitionBoundSpec *partbound; /* FOR VALUES clause */ + PartitionBoundSpec *partbound; /* FOR VALUES clause */ PartitionSpec *partspec; /* PARTITION BY clause */ TypeName *ofTypename; /* OF typename */ List *constraints; /* constraints (list of Constraint nodes) */ @@ -2124,7 +2123,8 @@ typedef struct Constraint char fk_upd_action; /* ON UPDATE action */ char fk_del_action; /* ON DELETE action */ List *old_conpfeqop; /* pg_constraint.conpfeqop of my former self */ - Oid old_pktable_oid; /* pg_constraint.confrelid of my former self */ + Oid old_pktable_oid; /* pg_constraint.confrelid of my former + * self */ /* Fields used for constraints that allow a NOT VALID specification */ bool skip_validation; /* skip validation of existing rows? */ @@ -2996,7 +2996,7 @@ typedef struct AlterEnumStmt char *newVal; /* new enum value's name */ char *newValNeighbor; /* neighboring enum value, if specified */ bool newValIsAfter; /* place new enum value after neighbor? */ - bool skipIfNewValExists; /* no error if new already exists? */ + bool skipIfNewValExists; /* no error if new already exists? */ } AlterEnumStmt; /* ---------------------- @@ -3110,7 +3110,7 @@ typedef enum VacuumOption VACOPT_FULL = 1 << 4, /* FULL (non-concurrent) vacuum */ VACOPT_NOWAIT = 1 << 5, /* don't wait to get lock (autovacuum only) */ VACOPT_SKIPTOAST = 1 << 6, /* don't process the TOAST table, if any */ - VACOPT_DISABLE_PAGE_SKIPPING = 1 << 7, /* don't skip any pages */ + VACOPT_DISABLE_PAGE_SKIPPING = 1 << 7, /* don't skip any pages */ VACOPT_COORDINATOR = 1 << 8 /* don't trigger analyze on the datanodes, but * just collect existing info and populate * coordinator side stats. @@ -3311,7 +3311,7 @@ typedef struct ConstraintsSetStmt */ /* Reindex options */ -#define REINDEXOPT_VERBOSE 1 << 0 /* print progress info */ +#define REINDEXOPT_VERBOSE 1 << 0 /* print progress info */ typedef enum ReindexObjectType { @@ -3340,8 +3340,8 @@ typedef struct CreateConversionStmt { NodeTag type; List *conversion_name; /* Name of the conversion */ - char *for_encoding_name; /* source encoding name */ - char *to_encoding_name; /* destination encoding name */ + char *for_encoding_name; /* source encoding name */ + char *to_encoding_name; /* destination encoding name */ List *func_name; /* qualified conversion function name */ bool def; /* is this a default conversion? */ } CreateConversionStmt; @@ -3554,4 +3554,4 @@ typedef struct DropSubscriptionStmt DropBehavior behavior; /* RESTRICT or CASCADE behavior */ } DropSubscriptionStmt; -#endif /* PARSENODES_H */ +#endif /* PARSENODES_H */ diff --git a/src/include/nodes/pg_list.h b/src/include/nodes/pg_list.h index 8395bb4322..feee49ae53 100644 --- a/src/include/nodes/pg_list.h +++ b/src/include/nodes/pg_list.h @@ -340,6 +340,6 @@ extern List *list_copy_tail(const List *list, int nskip); #define listCopy(list) list_copy(list) extern int length(List *list); -#endif /* ENABLE_LIST_COMPAT */ +#endif /* ENABLE_LIST_COMPAT */ -#endif /* PG_LIST_H */ +#endif /* PG_LIST_H */ diff --git a/src/include/nodes/plannodes.h b/src/include/nodes/plannodes.h index a4b9f18aa5..0fcc5607bb 100644 --- a/src/include/nodes/plannodes.h +++ b/src/include/nodes/plannodes.h @@ -57,7 +57,7 @@ typedef struct PlannedStmt bool dependsOnRole; /* is plan specific to current role? */ - bool parallelModeNeeded; /* parallel mode required to execute? */ + bool parallelModeNeeded; /* parallel mode required to execute? */ struct Plan *planTree; /* tree of Plan nodes */ @@ -235,7 +235,7 @@ typedef struct ModifyTable List *partitioned_rels; List *resultRelations; /* integer list of RT indexes */ int resultRelIndex; /* index of first resultRel in plan's list */ - int rootResultRelIndex; /* index of the partitioned table root */ + int rootResultRelIndex; /* index of the partitioned table root */ List *plans; /* plan(s) producing source data */ List *withCheckOptionLists; /* per-target-table WCO lists */ List *returningLists; /* per-target-table RETURNING tlists */ @@ -404,7 +404,7 @@ typedef struct IndexScan List *indexqual; /* list of index quals (usually OpExprs) */ List *indexqualorig; /* the same in original form */ List *indexorderby; /* list of index ORDER BY exprs */ - List *indexorderbyorig; /* the same in original form */ + List *indexorderbyorig; /* the same in original form */ List *indexorderbyops; /* OIDs of sort ops for ORDER BY exprs */ ScanDirection indexorderdir; /* forward or backward or don't care */ } IndexScan; @@ -614,8 +614,7 @@ typedef struct ForeignScan List *fdw_exprs; /* expressions that FDW may evaluate */ List *fdw_private; /* private data for FDW */ List *fdw_scan_tlist; /* optional tlist describing scan tuple */ - List *fdw_recheck_quals; /* original quals not in - * scan.plan.qual */ + List *fdw_recheck_quals; /* original quals not in scan.plan.qual */ Bitmapset *fs_relids; /* RTIs generated by this scan */ bool fsSystemCol; /* true if any "system column" is needed */ } ForeignScan; @@ -643,8 +642,7 @@ typedef struct CustomScan List *custom_plans; /* list of Plan nodes, if any */ List *custom_exprs; /* expressions that custom code may evaluate */ List *custom_private; /* private data for custom code */ - List *custom_scan_tlist; /* optional tlist describing scan - * tuple */ + List *custom_scan_tlist; /* optional tlist describing scan tuple */ Bitmapset *custom_relids; /* RTIs generated by this scan */ const struct CustomScanMethods *methods; } CustomScan; @@ -723,7 +721,7 @@ typedef struct NestLoopParam typedef struct MergeJoin { Join join; - bool skip_mark_restore; /* Can we skip mark/restore calls? */ + bool skip_mark_restore; /* Can we skip mark/restore calls? */ List *mergeclauses; /* mergeclauses as expression trees */ /* these are arrays, but have the same length as the mergeclauses list: */ Oid *mergeFamilies; /* per-clause OIDs of btree opfamilies */ @@ -1044,4 +1042,4 @@ typedef struct PlanInvalItem uint32 hashValue; /* hash value of object's cache lookup key */ } PlanInvalItem; -#endif /* PLANNODES_H */ +#endif /* PLANNODES_H */ diff --git a/src/include/nodes/primnodes.h b/src/include/nodes/primnodes.h index 66dd6b50e4..72bd50ac3e 100644 --- a/src/include/nodes/primnodes.h +++ b/src/include/nodes/primnodes.h @@ -156,9 +156,9 @@ typedef struct Expr * are very useful for debugging and interpreting completed plans, so we keep * them around. */ -#define INNER_VAR 65000 /* reference to inner subplan */ -#define OUTER_VAR 65001 /* reference to outer subplan */ -#define INDEX_VAR 65002 /* reference to index column */ +#define INNER_VAR 65000 /* reference to inner subplan */ +#define OUTER_VAR 65001 /* reference to outer subplan */ +#define INDEX_VAR 65002 /* reference to index column */ #define IS_SPECIAL_VARNO(varno) ((varno) >= INNER_VAR) @@ -410,10 +410,11 @@ typedef struct ArrayRef Oid refelemtype; /* type of the array elements */ int32 reftypmod; /* typmod of the array (and elements too) */ Oid refcollid; /* OID of collation, or InvalidOid if none */ - List *refupperindexpr;/* expressions that evaluate to upper array - * indexes */ - List *reflowerindexpr;/* expressions that evaluate to lower array - * indexes, or NIL for single array element */ + List *refupperindexpr; /* expressions that evaluate to upper + * array indexes */ + List *reflowerindexpr; /* expressions that evaluate to lower + * array indexes, or NIL for single array + * element */ Expr *refexpr; /* the expression that evaluates to an array * value */ Expr *refassgnexpr; /* expression for the source value, or NULL if @@ -701,8 +702,8 @@ typedef struct SubPlan /* Extra data useful for determining subplan's output type: */ Oid firstColType; /* Type of first column of subplan result */ int32 firstColTypmod; /* Typmod of first column of subplan result */ - Oid firstColCollation; /* Collation of first column of - * subplan result */ + Oid firstColCollation; /* Collation of first column of subplan + * result */ /* Information about execution strategy: */ bool useHashTable; /* TRUE to store subselect output in a hash * table (implies we are doing "IN") */ @@ -1377,8 +1378,8 @@ typedef struct TargetEntry Expr *expr; /* expression to evaluate */ AttrNumber resno; /* attribute number (see notes above) */ char *resname; /* name of the column (could be NULL) */ - Index ressortgroupref;/* nonzero if referenced by a sort/group - * clause */ + Index ressortgroupref; /* nonzero if referenced by a sort/group + * clause */ Oid resorigtbl; /* OID of column's source table */ AttrNumber resorigcol; /* column's number in source table */ bool resjunk; /* set to true to eliminate the attribute from @@ -1559,4 +1560,4 @@ typedef struct OnConflictExpr List *exclRelTlist; /* tlist of the EXCLUDED pseudo relation */ } OnConflictExpr; -#endif /* PRIMNODES_H */ +#endif /* PRIMNODES_H */ diff --git a/src/include/nodes/print.h b/src/include/nodes/print.h index 4c94a3afe5..fa01c2ad84 100644 --- a/src/include/nodes/print.h +++ b/src/include/nodes/print.h @@ -31,4 +31,4 @@ extern void print_pathkeys(const List *pathkeys, const List *rtable); extern void print_tl(const List *tlist, const List *rtable); extern void print_slot(TupleTableSlot *slot); -#endif /* PRINT_H */ +#endif /* PRINT_H */ diff --git a/src/include/nodes/readfuncs.h b/src/include/nodes/readfuncs.h index ca540baf02..c80fae2311 100644 --- a/src/include/nodes/readfuncs.h +++ b/src/include/nodes/readfuncs.h @@ -28,4 +28,4 @@ extern void *nodeRead(char *token, int tok_len); */ extern Node *parseNodeString(void); -#endif /* READFUNCS_H */ +#endif /* READFUNCS_H */ diff --git a/src/include/nodes/relation.h b/src/include/nodes/relation.h index 1e7e6942d5..d3d2f33ff3 100644 --- a/src/include/nodes/relation.h +++ b/src/include/nodes/relation.h @@ -148,9 +148,9 @@ typedef struct PlannerGlobal bool parallelModeOK; /* parallel mode potentially OK? */ - bool parallelModeNeeded; /* parallel mode actually required? */ + bool parallelModeNeeded; /* parallel mode actually required? */ - char maxParallelHazard; /* worst PROPARALLEL hazard level */ + char maxParallelHazard; /* worst PROPARALLEL hazard level */ } PlannerGlobal; /* macro for fetching the Plan associated with a SubPlan node */ @@ -196,7 +196,7 @@ typedef struct PlannerInfo * does not correspond to a base relation, such as a join RTE or an * unreferenced view RTE; or if the RelOptInfo hasn't been made yet. */ - struct RelOptInfo **simple_rel_array; /* All 1-rel RelOptInfos */ + struct RelOptInfo **simple_rel_array; /* All 1-rel RelOptInfos */ int simple_rel_array_size; /* allocated size of array */ /* @@ -249,23 +249,23 @@ typedef struct PlannerInfo List *cte_plan_ids; /* per-CTE-item list of subplan IDs */ - List *multiexpr_params; /* List of Lists of Params for - * MULTIEXPR subquery outputs */ + List *multiexpr_params; /* List of Lists of Params for MULTIEXPR + * subquery outputs */ List *eq_classes; /* list of active EquivalenceClasses */ List *canon_pathkeys; /* list of "canonical" PathKeys */ - List *left_join_clauses; /* list of RestrictInfos for - * mergejoinable outer join clauses - * w/nonnullable var on left */ + List *left_join_clauses; /* list of RestrictInfos for mergejoinable + * outer join clauses w/nonnullable var on + * left */ - List *right_join_clauses; /* list of RestrictInfos for - * mergejoinable outer join clauses - * w/nonnullable var on right */ + List *right_join_clauses; /* list of RestrictInfos for mergejoinable + * outer join clauses w/nonnullable var on + * right */ - List *full_join_clauses; /* list of RestrictInfos for - * mergejoinable full join clauses */ + List *full_join_clauses; /* list of RestrictInfos for mergejoinable + * full join clauses */ List *join_info_list; /* list of SpecialJoinInfos */ @@ -275,7 +275,7 @@ typedef struct PlannerInfo List *rowMarks; /* list of PlanRowMarks */ - List *placeholder_list; /* list of PlaceHolderInfos */ + List *placeholder_list; /* list of PlaceHolderInfos */ List *fkey_list; /* list of ForeignKeyOptInfos */ @@ -283,7 +283,7 @@ typedef struct PlannerInfo List *group_pathkeys; /* groupClause pathkeys, if any */ List *window_pathkeys; /* pathkeys of bottom window, if any */ - List *distinct_pathkeys; /* distinctClause pathkeys, if any */ + List *distinct_pathkeys; /* distinctClause pathkeys, if any */ List *sort_pathkeys; /* sortClause pathkeys, if any */ List *initial_rels; /* RelOptInfos we are now trying to join */ @@ -306,7 +306,7 @@ typedef struct PlannerInfo MemoryContext planner_cxt; /* context holding PlannerInfo */ - double total_table_pages; /* # of pages in all tables of query */ + double total_table_pages; /* # of pages in all tables of query */ double tuple_fraction; /* tuple_fraction passed to query_planner */ double limit_tuples; /* limit_tuples passed to query_planner */ @@ -314,8 +314,8 @@ typedef struct PlannerInfo Index qual_security_level; /* minimum security_level for quals */ /* Note: qual_security_level is zero if there are no securityQuals */ - bool hasInheritedTarget; /* true if parse->resultRelation is an - * inheritance child rel */ + bool hasInheritedTarget; /* true if parse->resultRelation is an + * inheritance child rel */ bool hasJoinRTEs; /* true if any RTEs are RTE_JOIN kind */ bool hasLateralRTEs; /* true if any RTEs are marked LATERAL */ bool hasDeletedRTEs; /* true if any RTE was deleted from jointree */ @@ -560,17 +560,17 @@ typedef struct RelOptInfo double rows; /* estimated number of result tuples */ /* per-relation planner control flags */ - bool consider_startup; /* keep cheap-startup-cost paths? */ + bool consider_startup; /* keep cheap-startup-cost paths? */ bool consider_param_startup; /* ditto, for parameterized paths? */ - bool consider_parallel; /* consider parallel paths? */ + bool consider_parallel; /* consider parallel paths? */ /* default result targetlist for Paths scanning this relation */ - struct PathTarget *reltarget; /* list of Vars/Exprs, cost, width */ + struct PathTarget *reltarget; /* list of Vars/Exprs, cost, width */ /* materialization information */ List *pathlist; /* Path structures */ List *ppilist; /* ParamPathInfos used in pathlist */ - List *partial_pathlist; /* partial Paths */ + List *partial_pathlist; /* partial Paths */ struct Path *cheapest_startup_path; struct Path *cheapest_total_path; struct Path *cheapest_unique_path; @@ -609,21 +609,21 @@ typedef struct RelOptInfo void *fdw_private; /* cache space for remembering if we have proven this relation unique */ - List *unique_for_rels; /* known unique for these other relid set(s) */ + List *unique_for_rels; /* known unique for these other relid + * set(s) */ List *non_unique_for_rels; /* known not unique for these set(s) */ /* used by various scans and joins: */ - List *baserestrictinfo; /* RestrictInfo structures (if base - * rel) */ - QualCost baserestrictcost; /* cost of evaluating the above */ - Index baserestrict_min_security; /* min security_level found in - * baserestrictinfo */ + List *baserestrictinfo; /* RestrictInfo structures (if base rel) */ + QualCost baserestrictcost; /* cost of evaluating the above */ + Index baserestrict_min_security; /* min security_level found in + * baserestrictinfo */ List *joininfo; /* RestrictInfo structures for join clauses * involving this rel */ - bool has_eclass_joins; /* T means joininfo is incomplete */ + bool has_eclass_joins; /* T means joininfo is incomplete */ /* used by "other" relations */ - Relids top_parent_relids; /* Relids of topmost parents */ + Relids top_parent_relids; /* Relids of topmost parents */ } RelOptInfo; /* @@ -687,10 +687,11 @@ typedef struct IndexOptInfo List *indextlist; /* targetlist representing index columns */ - List *indrestrictinfo;/* parent relation's baserestrictinfo list, - * less any conditions implied by the index's - * predicate (unless it's a target rel, see - * comments in check_index_predicates()) */ + List *indrestrictinfo; /* parent relation's baserestrictinfo + * list, less any conditions implied by + * the index's predicate (unless it's a + * target rel, see comments in + * check_index_predicates()) */ bool predOK; /* true if index predicate matches query */ bool unique; /* true if a unique index */ @@ -726,8 +727,8 @@ typedef struct ForeignKeyOptInfo Index ref_relid; /* RT index of the referenced table */ int nkeys; /* number of columns in the foreign key */ AttrNumber conkey[INDEX_MAX_KEYS]; /* cols in referencing table */ - AttrNumber confkey[INDEX_MAX_KEYS]; /* cols in referenced table */ - Oid conpfeqop[INDEX_MAX_KEYS]; /* PK = FK operator OIDs */ + AttrNumber confkey[INDEX_MAX_KEYS]; /* cols in referenced table */ + Oid conpfeqop[INDEX_MAX_KEYS]; /* PK = FK operator OIDs */ /* Derived info about whether FK's equality conditions match the query: */ int nmatched_ec; /* # of FK cols matched by ECs */ @@ -852,7 +853,7 @@ typedef struct EquivalenceMember Expr *em_expr; /* the expression represented */ Relids em_relids; /* all relids appearing in em_expr */ - Relids em_nullable_relids; /* nullable by lower outer joins */ + Relids em_nullable_relids; /* nullable by lower outer joins */ bool em_is_const; /* expression is pseudoconstant? */ bool em_is_child; /* derived version for a child relation? */ Oid em_datatype; /* the "nominal type" used by the opfamily */ @@ -989,8 +990,7 @@ typedef struct Path bool parallel_aware; /* engage parallel-aware logic? */ bool parallel_safe; /* OK to use as part of parallel plan? */ - int parallel_workers; /* desired # of workers; 0 = not - * parallel */ + int parallel_workers; /* desired # of workers; 0 = not parallel */ /* estimated size/costs for path (see costsize.c for more info) */ double rows; /* estimated number of result tuples */ @@ -1339,7 +1339,7 @@ typedef struct JoinPath Path *outerjoinpath; /* path for the outer side of the join */ Path *innerjoinpath; /* path for the inner side of the join */ - List *joinrestrictinfo; /* RestrictInfos to apply to join */ + List *joinrestrictinfo; /* RestrictInfos to apply to join */ #ifdef XCP List *movedrestrictinfo; /* RestrictInfos moved down to inner path */ @@ -1396,11 +1396,11 @@ typedef JoinPath NestPath; typedef struct MergePath { JoinPath jpath; - List *path_mergeclauses; /* join clauses to be used for merge */ + List *path_mergeclauses; /* join clauses to be used for merge */ List *outersortkeys; /* keys for explicit sort, if any */ List *innersortkeys; /* keys for explicit sort, if any */ - bool skip_mark_restore; /* can executor skip mark/restore? */ - bool materialize_inner; /* add Materialize to inner? */ + bool skip_mark_restore; /* can executor skip mark/restore? */ + bool materialize_inner; /* add Materialize to inner? */ } MergePath; /* @@ -1415,7 +1415,7 @@ typedef struct MergePath typedef struct HashPath { JoinPath jpath; - List *path_hashclauses; /* join clauses used for hashing */ + List *path_hashclauses; /* join clauses used for hashing */ int num_batches; /* number of batches expected */ } HashPath; @@ -1795,7 +1795,7 @@ typedef struct RestrictInfo bool is_pushed_down; /* TRUE if clause was pushed down in level */ - bool outerjoin_delayed; /* TRUE if delayed by lower outer join */ + bool outerjoin_delayed; /* TRUE if delayed by lower outer join */ bool can_join; /* see comment above */ @@ -1849,11 +1849,11 @@ typedef struct RestrictInfo bool outer_is_left; /* T = outer var on left, F = on right */ /* valid if clause is hashjoinable, else InvalidOid: */ - Oid hashjoinoperator; /* copy of clause operator */ + Oid hashjoinoperator; /* copy of clause operator */ /* cache space for hashclause processing; -1 if not yet set */ Selectivity left_bucketsize; /* avg bucketsize of left side */ - Selectivity right_bucketsize; /* avg bucketsize of right side */ + Selectivity right_bucketsize; /* avg bucketsize of right side */ } RestrictInfo; /* @@ -1967,7 +1967,7 @@ typedef struct SpecialJoinInfo Relids syn_righthand; /* base relids syntactically within RHS */ JoinType jointype; /* always INNER, LEFT, FULL, SEMI, or ANTI */ bool lhs_strict; /* joinclause is strict for some LHS rel */ - bool delay_upper_joins; /* can't commute with upper RHS */ + bool delay_upper_joins; /* can't commute with upper RHS */ /* Remaining fields are set only for JOIN_SEMI jointype: */ bool semi_can_btree; /* true if semi_operators are all btree */ bool semi_can_hash; /* true if semi_operators are all hash */ @@ -2268,4 +2268,4 @@ typedef struct JoinCostWorkspace int numbatches; } JoinCostWorkspace; -#endif /* RELATION_H */ +#endif /* RELATION_H */ diff --git a/src/include/nodes/replnodes.h b/src/include/nodes/replnodes.h index 92ada41b6d..dea61e90e9 100644 --- a/src/include/nodes/replnodes.h +++ b/src/include/nodes/replnodes.h @@ -105,4 +105,4 @@ typedef struct SQLCmd NodeTag type; } SQLCmd; -#endif /* REPLNODES_H */ +#endif /* REPLNODES_H */ diff --git a/src/include/nodes/tidbitmap.h b/src/include/nodes/tidbitmap.h index 87f4bb7c91..f9a1902da8 100644 --- a/src/include/nodes/tidbitmap.h +++ b/src/include/nodes/tidbitmap.h @@ -71,4 +71,4 @@ extern void tbm_end_shared_iterate(TBMSharedIterator *iterator); extern TBMSharedIterator *tbm_attach_shared_iterate(dsa_area *dsa, dsa_pointer dp); -#endif /* TIDBITMAP_H */ +#endif /* TIDBITMAP_H */ diff --git a/src/include/nodes/value.h b/src/include/nodes/value.h index ede97b7bcd..83f5a19fe9 100644 --- a/src/include/nodes/value.h +++ b/src/include/nodes/value.h @@ -58,4 +58,4 @@ extern Value *makeFloat(char *numericStr); extern Value *makeString(char *str); extern Value *makeBitString(char *str); -#endif /* VALUE_H */ +#endif /* VALUE_H */ diff --git a/src/include/optimizer/clauses.h b/src/include/optimizer/clauses.h index cc0d7b0a26..e3672218f3 100644 --- a/src/include/optimizer/clauses.h +++ b/src/include/optimizer/clauses.h @@ -85,4 +85,4 @@ extern Node *estimate_expression_value(PlannerInfo *root, Node *node); extern Query *inline_set_returning_function(PlannerInfo *root, RangeTblEntry *rte); -#endif /* CLAUSES_H */ +#endif /* CLAUSES_H */ diff --git a/src/include/optimizer/cost.h b/src/include/optimizer/cost.h index 2701500a4a..da34133a12 100644 --- a/src/include/optimizer/cost.h +++ b/src/include/optimizer/cost.h @@ -40,8 +40,8 @@ typedef enum { CONSTRAINT_EXCLUSION_OFF, /* do not use c_e */ CONSTRAINT_EXCLUSION_ON, /* apply c_e to all rels */ - CONSTRAINT_EXCLUSION_PARTITION /* apply c_e to otherrels only */ -} ConstraintExclusionType; + CONSTRAINT_EXCLUSION_PARTITION /* apply c_e to otherrels only */ +} ConstraintExclusionType; /* @@ -207,7 +207,7 @@ extern void set_namedtuplestore_size_estimates(PlannerInfo *root, RelOptInfo *re extern void set_foreign_size_estimates(PlannerInfo *root, RelOptInfo *rel); extern PathTarget *set_pathtarget_cost_width(PlannerInfo *root, PathTarget *target); extern double compute_bitmap_pages(PlannerInfo *root, RelOptInfo *baserel, - Path *bitmapqual, int loop_count, Cost *cost, double *tuple); + Path *bitmapqual, int loop_count, Cost *cost, double *tuple); /* * prototypes for clausesel.c @@ -228,4 +228,4 @@ extern void cost_gather_merge(GatherMergePath *path, PlannerInfo *root, Cost input_startup_cost, Cost input_total_cost, double *rows); -#endif /* COST_H */ +#endif /* COST_H */ diff --git a/src/include/optimizer/geqo.h b/src/include/optimizer/geqo.h index be65c054e1..d0158d7adf 100644 --- a/src/include/optimizer/geqo.h +++ b/src/include/optimizer/geqo.h @@ -73,7 +73,7 @@ extern double Geqo_seed; /* 0 .. 1 */ typedef struct { List *initial_rels; /* the base relations we are joining */ - unsigned short random_state[3]; /* state for pg_erand48() */ + unsigned short random_state[3]; /* state for pg_erand48() */ } GeqoPrivateData; @@ -85,4 +85,4 @@ extern RelOptInfo *geqo(PlannerInfo *root, extern Cost geqo_eval(PlannerInfo *root, Gene *tour, int num_gene); extern RelOptInfo *gimme_tree(PlannerInfo *root, Gene *tour, int num_gene); -#endif /* GEQO_H */ +#endif /* GEQO_H */ diff --git a/src/include/optimizer/geqo_copy.h b/src/include/optimizer/geqo_copy.h index 3cbaf3e4ca..4035b4ff13 100644 --- a/src/include/optimizer/geqo_copy.h +++ b/src/include/optimizer/geqo_copy.h @@ -27,4 +27,4 @@ extern void geqo_copy(PlannerInfo *root, Chromosome *chromo1, Chromosome *chromo2, int string_length); -#endif /* GEQO_COPY_H */ +#endif /* GEQO_COPY_H */ diff --git a/src/include/optimizer/geqo_gene.h b/src/include/optimizer/geqo_gene.h index f936ebdd89..3282193284 100644 --- a/src/include/optimizer/geqo_gene.h +++ b/src/include/optimizer/geqo_gene.h @@ -42,4 +42,4 @@ typedef struct Pool int string_length; } Pool; -#endif /* GEQO_GENE_H */ +#endif /* GEQO_GENE_H */ diff --git a/src/include/optimizer/geqo_misc.h b/src/include/optimizer/geqo_misc.h index 880bd0e140..89f91b3a4d 100644 --- a/src/include/optimizer/geqo_misc.h +++ b/src/include/optimizer/geqo_misc.h @@ -29,6 +29,6 @@ extern void print_pool(FILE *fp, Pool *pool, int start, int stop); extern void print_gen(FILE *fp, Pool *pool, int generation); extern void print_edge_table(FILE *fp, Edge *edge_table, int num_gene); -#endif /* GEQO_DEBUG */ +#endif /* GEQO_DEBUG */ -#endif /* GEQO_MISC_H */ +#endif /* GEQO_MISC_H */ diff --git a/src/include/optimizer/geqo_mutation.h b/src/include/optimizer/geqo_mutation.h index 85781c3c31..c5a94e03cf 100644 --- a/src/include/optimizer/geqo_mutation.h +++ b/src/include/optimizer/geqo_mutation.h @@ -27,4 +27,4 @@ extern void geqo_mutation(PlannerInfo *root, Gene *tour, int num_gene); -#endif /* GEQO_MUTATION_H */ +#endif /* GEQO_MUTATION_H */ diff --git a/src/include/optimizer/geqo_pool.h b/src/include/optimizer/geqo_pool.h index 7947b6e5bb..9fac307d69 100644 --- a/src/include/optimizer/geqo_pool.h +++ b/src/include/optimizer/geqo_pool.h @@ -37,4 +37,4 @@ extern void spread_chromo(PlannerInfo *root, Chromosome *chromo, Pool *pool); extern void sort_pool(PlannerInfo *root, Pool *pool); -#endif /* GEQO_POOL_H */ +#endif /* GEQO_POOL_H */ diff --git a/src/include/optimizer/geqo_random.h b/src/include/optimizer/geqo_random.h index 5312589387..2665a096b3 100644 --- a/src/include/optimizer/geqo_random.h +++ b/src/include/optimizer/geqo_random.h @@ -38,4 +38,4 @@ extern double geqo_rand(PlannerInfo *root); #define geqo_randint(root, upper, lower) \ ( (int) floor( geqo_rand(root)*(((upper)-(lower))+0.999999) ) + (lower) ) -#endif /* GEQO_RANDOM_H */ +#endif /* GEQO_RANDOM_H */ diff --git a/src/include/optimizer/geqo_recombination.h b/src/include/optimizer/geqo_recombination.h index 8ddde22296..8a436b9ec2 100644 --- a/src/include/optimizer/geqo_recombination.h +++ b/src/include/optimizer/geqo_recombination.h @@ -86,4 +86,4 @@ extern void ox1(PlannerInfo *root, Gene *mom, Gene *dad, Gene *offspring, extern void ox2(PlannerInfo *root, Gene *mom, Gene *dad, Gene *offspring, int num_gene, City *city_table); -#endif /* GEQO_RECOMBINATION_H */ +#endif /* GEQO_RECOMBINATION_H */ diff --git a/src/include/optimizer/geqo_selection.h b/src/include/optimizer/geqo_selection.h index 1aecf14ac1..69ce2b4b8a 100644 --- a/src/include/optimizer/geqo_selection.h +++ b/src/include/optimizer/geqo_selection.h @@ -30,4 +30,4 @@ extern void geqo_selection(PlannerInfo *root, Chromosome *momma, Chromosome *daddy, Pool *pool, double bias); -#endif /* GEQO_SELECTION_H */ +#endif /* GEQO_SELECTION_H */ diff --git a/src/include/optimizer/joininfo.h b/src/include/optimizer/joininfo.h index c9a8b53f1f..4450d81408 100644 --- a/src/include/optimizer/joininfo.h +++ b/src/include/optimizer/joininfo.h @@ -27,4 +27,4 @@ extern void remove_join_clause_from_rels(PlannerInfo *root, RestrictInfo *restrictinfo, Relids join_relids); -#endif /* JOININFO_H */ +#endif /* JOININFO_H */ diff --git a/src/include/optimizer/orclauses.h b/src/include/optimizer/orclauses.h index 2512ddee8f..a3d8e1d9f9 100644 --- a/src/include/optimizer/orclauses.h +++ b/src/include/optimizer/orclauses.h @@ -18,4 +18,4 @@ extern void extract_restriction_or_clauses(PlannerInfo *root); -#endif /* ORCLAUSES_H */ +#endif /* ORCLAUSES_H */ diff --git a/src/include/optimizer/pathnode.h b/src/include/optimizer/pathnode.h index 7937deebda..daf427a838 100644 --- a/src/include/optimizer/pathnode.h +++ b/src/include/optimizer/pathnode.h @@ -290,4 +290,4 @@ extern ParamPathInfo *get_joinrel_parampathinfo(PlannerInfo *root, extern ParamPathInfo *get_appendrel_parampathinfo(RelOptInfo *appendrel, Relids required_outer); -#endif /* PATHNODE_H */ +#endif /* PATHNODE_H */ diff --git a/src/include/optimizer/paths.h b/src/include/optimizer/paths.h index a216f9e912..4e06b2e299 100644 --- a/src/include/optimizer/paths.h +++ b/src/include/optimizer/paths.h @@ -27,24 +27,24 @@ extern int min_parallel_index_scan_size; /* Hook for plugins to get control in set_rel_pathlist() */ typedef void (*set_rel_pathlist_hook_type) (PlannerInfo *root, - RelOptInfo *rel, - Index rti, - RangeTblEntry *rte); + RelOptInfo *rel, + Index rti, + RangeTblEntry *rte); extern PGDLLIMPORT set_rel_pathlist_hook_type set_rel_pathlist_hook; /* Hook for plugins to get control in add_paths_to_joinrel() */ typedef void (*set_join_pathlist_hook_type) (PlannerInfo *root, - RelOptInfo *joinrel, - RelOptInfo *outerrel, - RelOptInfo *innerrel, - JoinType jointype, - JoinPathExtraData *extra); + RelOptInfo *joinrel, + RelOptInfo *outerrel, + RelOptInfo *innerrel, + JoinType jointype, + JoinPathExtraData *extra); extern PGDLLIMPORT set_join_pathlist_hook_type set_join_pathlist_hook; /* Hook for plugins to replace standard_join_search() */ typedef RelOptInfo *(*join_search_hook_type) (PlannerInfo *root, - int levels_needed, - List *initial_rels); + int levels_needed, + List *initial_rels); extern PGDLLIMPORT join_search_hook_type join_search_hook; @@ -117,10 +117,10 @@ extern bool have_dangerous_phv(PlannerInfo *root, * routines for managing EquivalenceClasses */ typedef bool (*ec_matches_callback_type) (PlannerInfo *root, - RelOptInfo *rel, - EquivalenceClass *ec, - EquivalenceMember *em, - void *arg); + RelOptInfo *rel, + EquivalenceClass *ec, + EquivalenceMember *em, + void *arg); extern bool process_equivalence(PlannerInfo *root, RestrictInfo *restrictinfo, bool below_outer_join); @@ -228,4 +228,4 @@ extern PathKey *make_canonical_pathkey(PlannerInfo *root, EquivalenceClass *eclass, Oid opfamily, int strategy, bool nulls_first); -#endif /* PATHS_H */ +#endif /* PATHS_H */ diff --git a/src/include/optimizer/placeholder.h b/src/include/optimizer/placeholder.h index 11e6403aa3..5a4d46ba9d 100644 --- a/src/include/optimizer/placeholder.h +++ b/src/include/optimizer/placeholder.h @@ -29,4 +29,4 @@ extern void add_placeholders_to_base_rels(PlannerInfo *root); extern void add_placeholders_to_joinrel(PlannerInfo *root, RelOptInfo *joinrel, RelOptInfo *outer_rel, RelOptInfo *inner_rel); -#endif /* PLACEHOLDER_H */ +#endif /* PLACEHOLDER_H */ diff --git a/src/include/optimizer/plancat.h b/src/include/optimizer/plancat.h index 68fd713b09..71f0faf938 100644 --- a/src/include/optimizer/plancat.h +++ b/src/include/optimizer/plancat.h @@ -19,9 +19,9 @@ /* Hook for plugins to get control in get_relation_info() */ typedef void (*get_relation_info_hook_type) (PlannerInfo *root, - Oid relationObjectId, - bool inhparent, - RelOptInfo *rel); + Oid relationObjectId, + bool inhparent, + RelOptInfo *rel); extern PGDLLIMPORT get_relation_info_hook_type get_relation_info_hook; @@ -57,4 +57,4 @@ extern Selectivity join_selectivity(PlannerInfo *root, extern bool has_row_triggers(PlannerInfo *root, Index rti, CmdType event); -#endif /* PLANCAT_H */ +#endif /* PLANCAT_H */ diff --git a/src/include/optimizer/planmain.h b/src/include/optimizer/planmain.h index 4ef9ddb2ba..9068b03666 100644 --- a/src/include/optimizer/planmain.h +++ b/src/include/optimizer/planmain.h @@ -27,7 +27,7 @@ typedef enum FORCE_PARALLEL_OFF, FORCE_PARALLEL_ON, FORCE_PARALLEL_REGRESS -} ForceParallelMode; +} ForceParallelMode; /* GUC parameters */ #define DEFAULT_CURSOR_TUPLE_FRACTION 0.1 @@ -130,4 +130,4 @@ extern void extract_query_dependencies(Node *query, List **invalItems, bool *hasRowSecurity); -#endif /* PLANMAIN_H */ +#endif /* PLANMAIN_H */ diff --git a/src/include/optimizer/planner.h b/src/include/optimizer/planner.h index 99ddafb4f3..a59625cd27 100644 --- a/src/include/optimizer/planner.h +++ b/src/include/optimizer/planner.h @@ -20,15 +20,15 @@ /* Hook for plugins to get control in planner() */ typedef PlannedStmt *(*planner_hook_type) (Query *parse, - int cursorOptions, - ParamListInfo boundParams); + int cursorOptions, + ParamListInfo boundParams); extern PGDLLIMPORT planner_hook_type planner_hook; /* Hook for plugins to get control when grouping_planner() plans upper rels */ typedef void (*create_upper_paths_hook_type) (PlannerInfo *root, - UpperRelationKind stage, - RelOptInfo *input_rel, - RelOptInfo *output_rel); + UpperRelationKind stage, + RelOptInfo *input_rel, + RelOptInfo *output_rel); extern PGDLLIMPORT create_upper_paths_hook_type create_upper_paths_hook; @@ -63,4 +63,4 @@ extern bool plan_cluster_use_sort(Oid tableOid, Oid indexOid); extern List *get_partitioned_child_rels(PlannerInfo *root, Index rti); -#endif /* PLANNER_H */ +#endif /* PLANNER_H */ diff --git a/src/include/optimizer/predtest.h b/src/include/optimizer/predtest.h index 748cd35611..bccb8d63a9 100644 --- a/src/include/optimizer/predtest.h +++ b/src/include/optimizer/predtest.h @@ -22,4 +22,4 @@ extern bool predicate_implied_by(List *predicate_list, List *clause_list, extern bool predicate_refuted_by(List *predicate_list, List *clause_list, bool clause_is_check); -#endif /* PREDTEST_H */ +#endif /* PREDTEST_H */ diff --git a/src/include/optimizer/prep.h b/src/include/optimizer/prep.h index 2b20b36f74..faad46b5e4 100644 --- a/src/include/optimizer/prep.h +++ b/src/include/optimizer/prep.h @@ -58,4 +58,4 @@ extern Node *adjust_appendrel_attrs(PlannerInfo *root, Node *node, extern Node *adjust_appendrel_attrs_multilevel(PlannerInfo *root, Node *node, RelOptInfo *child_rel); -#endif /* PREP_H */ +#endif /* PREP_H */ diff --git a/src/include/optimizer/restrictinfo.h b/src/include/optimizer/restrictinfo.h index 31b9a79285..b2a69998fd 100644 --- a/src/include/optimizer/restrictinfo.h +++ b/src/include/optimizer/restrictinfo.h @@ -43,4 +43,4 @@ extern bool join_clause_is_movable_into(RestrictInfo *rinfo, Relids currentrelids, Relids current_and_outer); -#endif /* RESTRICTINFO_H */ +#endif /* RESTRICTINFO_H */ diff --git a/src/include/optimizer/subselect.h b/src/include/optimizer/subselect.h index 56dc237b51..ecd2011d54 100644 --- a/src/include/optimizer/subselect.h +++ b/src/include/optimizer/subselect.h @@ -40,4 +40,4 @@ extern Param *assign_nestloop_param_placeholdervar(PlannerInfo *root, PlaceHolderVar *phv); extern int SS_assign_special_param(PlannerInfo *root); -#endif /* SUBSELECT_H */ +#endif /* SUBSELECT_H */ diff --git a/src/include/optimizer/tlist.h b/src/include/optimizer/tlist.h index ccb93d8c80..0d3ec920dd 100644 --- a/src/include/optimizer/tlist.h +++ b/src/include/optimizer/tlist.h @@ -69,4 +69,4 @@ extern void split_pathtarget_at_srfs(PlannerInfo *root, #define create_pathtarget(root, tlist) \ set_pathtarget_cost_width(root, make_pathtarget_from_tlist(tlist)) -#endif /* TLIST_H */ +#endif /* TLIST_H */ diff --git a/src/include/optimizer/var.h b/src/include/optimizer/var.h index ae1f856933..61861528af 100644 --- a/src/include/optimizer/var.h +++ b/src/include/optimizer/var.h @@ -21,10 +21,10 @@ #define PVC_RECURSE_AGGREGATES 0x0002 /* recurse into Aggref arguments */ #define PVC_INCLUDE_WINDOWFUNCS 0x0004 /* include WindowFuncs in output list */ #define PVC_RECURSE_WINDOWFUNCS 0x0008 /* recurse into WindowFunc arguments */ -#define PVC_INCLUDE_PLACEHOLDERS 0x0010 /* include PlaceHolderVars in - * output list */ -#define PVC_RECURSE_PLACEHOLDERS 0x0020 /* recurse into PlaceHolderVar - * arguments */ +#define PVC_INCLUDE_PLACEHOLDERS 0x0010 /* include PlaceHolderVars in + * output list */ +#define PVC_RECURSE_PLACEHOLDERS 0x0020 /* recurse into PlaceHolderVar + * arguments */ extern Relids pull_varnos(Node *node); @@ -37,4 +37,4 @@ extern int locate_var_of_level(Node *node, int levelsup); extern List *pull_var_clause(Node *node, int flags); extern Node *flatten_join_alias_vars(PlannerInfo *root, Node *node); -#endif /* VAR_H */ +#endif /* VAR_H */ diff --git a/src/include/parser/analyze.h b/src/include/parser/analyze.h index 2c14b1e1af..42435884fe 100644 --- a/src/include/parser/analyze.h +++ b/src/include/parser/analyze.h @@ -19,7 +19,7 @@ /* Hook for plugins to get control at end of parse analysis */ typedef void (*post_parse_analyze_hook_type) (ParseState *pstate, - Query *query); + Query *query); extern PGDLLIMPORT post_parse_analyze_hook_type post_parse_analyze_hook; @@ -48,4 +48,4 @@ extern void applyLockingClause(Query *qry, Index rtindex, extern void ParseAnalyze_callback(ParseState *pstate, Query *query); extern post_parse_analyze_hook_type prev_ParseAnalyze_callback; #endif -#endif /* ANALYZE_H */ +#endif /* ANALYZE_H */ diff --git a/src/include/parser/gramparse.h b/src/include/parser/gramparse.h index 2da98f67f3..b6b67fb92c 100644 --- a/src/include/parser/gramparse.h +++ b/src/include/parser/gramparse.h @@ -44,8 +44,8 @@ typedef struct base_yy_extra_type */ bool have_lookahead; /* is lookahead info valid? */ int lookahead_token; /* one-token lookahead */ - core_YYSTYPE lookahead_yylval; /* yylval for lookahead token */ - YYLTYPE lookahead_yylloc; /* yylloc for lookahead token */ + core_YYSTYPE lookahead_yylval; /* yylval for lookahead token */ + YYLTYPE lookahead_yylloc; /* yylloc for lookahead token */ char *lookahead_end; /* end of current token */ char lookahead_hold_char; /* to be put back at *lookahead_end */ @@ -72,4 +72,4 @@ extern int base_yylex(YYSTYPE *lvalp, YYLTYPE *llocp, extern void parser_init(base_yy_extra_type *yyext); extern int base_yyparse(core_yyscan_t yyscanner); -#endif /* GRAMPARSE_H */ +#endif /* GRAMPARSE_H */ diff --git a/src/include/parser/parse_agg.h b/src/include/parser/parse_agg.h index 0ec3bc2e24..b9fd78d07a 100644 --- a/src/include/parser/parse_agg.h +++ b/src/include/parser/parse_agg.h @@ -66,4 +66,4 @@ extern void build_aggregate_finalfn_expr(Oid *agg_input_types, Oid finalfn_oid, Expr **finalfnexpr); -#endif /* PARSE_AGG_H */ +#endif /* PARSE_AGG_H */ diff --git a/src/include/parser/parse_clause.h b/src/include/parser/parse_clause.h index 823138f6c0..1d205c6327 100644 --- a/src/include/parser/parse_clause.h +++ b/src/include/parser/parse_clause.h @@ -51,4 +51,4 @@ extern List *addTargetToSortList(ParseState *pstate, TargetEntry *tle, extern Index assignSortGroupRef(TargetEntry *tle, List *tlist); extern bool targetIsInSortList(TargetEntry *tle, Oid sortop, List *sortList); -#endif /* PARSE_CLAUSE_H */ +#endif /* PARSE_CLAUSE_H */ diff --git a/src/include/parser/parse_coerce.h b/src/include/parser/parse_coerce.h index 3eed81966d..06f65293cb 100644 --- a/src/include/parser/parse_coerce.h +++ b/src/include/parser/parse_coerce.h @@ -91,4 +91,4 @@ extern CoercionPathType find_coercion_pathway(Oid targetTypeId, extern CoercionPathType find_typmod_coercion_function(Oid typeId, Oid *funcid); -#endif /* PARSE_COERCE_H */ +#endif /* PARSE_COERCE_H */ diff --git a/src/include/parser/parse_collate.h b/src/include/parser/parse_collate.h index e42971dfde..7279fa4e7c 100644 --- a/src/include/parser/parse_collate.h +++ b/src/include/parser/parse_collate.h @@ -24,4 +24,4 @@ extern void assign_expr_collations(ParseState *pstate, Node *expr); extern Oid select_common_collation(ParseState *pstate, List *exprs, bool none_ok); -#endif /* PARSE_COLLATE_H */ +#endif /* PARSE_COLLATE_H */ diff --git a/src/include/parser/parse_cte.h b/src/include/parser/parse_cte.h index 9130612312..695e88c7ed 100644 --- a/src/include/parser/parse_cte.h +++ b/src/include/parser/parse_cte.h @@ -21,4 +21,4 @@ extern List *transformWithClause(ParseState *pstate, WithClause *withClause); extern void analyzeCTETargetList(ParseState *pstate, CommonTableExpr *cte, List *tlist); -#endif /* PARSE_CTE_H */ +#endif /* PARSE_CTE_H */ diff --git a/src/include/parser/parse_enr.h b/src/include/parser/parse_enr.h index 48a7576f2c..9c68ddbb04 100644 --- a/src/include/parser/parse_enr.h +++ b/src/include/parser/parse_enr.h @@ -19,4 +19,4 @@ extern bool name_matches_visible_ENR(ParseState *pstate, const char *refname); extern EphemeralNamedRelationMetadata get_visible_ENR(ParseState *pstate, const char *refname); -#endif /* PARSE_ENR_H */ +#endif /* PARSE_ENR_H */ diff --git a/src/include/parser/parse_expr.h b/src/include/parser/parse_expr.h index 2101eaefda..3af09b0056 100644 --- a/src/include/parser/parse_expr.h +++ b/src/include/parser/parse_expr.h @@ -23,4 +23,4 @@ extern Node *transformExpr(ParseState *pstate, Node *expr, ParseExprKind exprKin extern const char *ParseExprKindName(ParseExprKind exprKind); -#endif /* PARSE_EXPR_H */ +#endif /* PARSE_EXPR_H */ diff --git a/src/include/parser/parse_func.h b/src/include/parser/parse_func.h index c684217e33..538b35bc17 100644 --- a/src/include/parser/parse_func.h +++ b/src/include/parser/parse_func.h @@ -71,4 +71,4 @@ extern void check_srf_call_placement(ParseState *pstate, Node *last_srf, int location); extern void check_pg_get_expr_args(ParseState *pstate, Oid fnoid, List *args); -#endif /* PARSE_FUNC_H */ +#endif /* PARSE_FUNC_H */ diff --git a/src/include/parser/parse_node.h b/src/include/parser/parse_node.h index 6a3507f3b1..68930c1f4a 100644 --- a/src/include/parser/parse_node.h +++ b/src/include/parser/parse_node.h @@ -43,7 +43,7 @@ typedef enum ParseExprKind EXPR_KIND_FILTER, /* FILTER */ EXPR_KIND_WINDOW_PARTITION, /* window definition PARTITION BY */ EXPR_KIND_WINDOW_ORDER, /* window definition ORDER BY */ - EXPR_KIND_WINDOW_FRAME_RANGE, /* window frame clause with RANGE */ + EXPR_KIND_WINDOW_FRAME_RANGE, /* window frame clause with RANGE */ EXPR_KIND_WINDOW_FRAME_ROWS, /* window frame clause with ROWS */ EXPR_KIND_SELECT_TARGET, /* SELECT target list item */ EXPR_KIND_INSERT_TARGET, /* INSERT target list item */ @@ -63,11 +63,11 @@ typedef enum ParseExprKind EXPR_KIND_FUNCTION_DEFAULT, /* default parameter value for function */ EXPR_KIND_INDEX_EXPRESSION, /* index expression */ EXPR_KIND_INDEX_PREDICATE, /* index predicate */ - EXPR_KIND_ALTER_COL_TRANSFORM, /* transform expr in ALTER COLUMN TYPE */ + EXPR_KIND_ALTER_COL_TRANSFORM, /* transform expr in ALTER COLUMN TYPE */ EXPR_KIND_EXECUTE_PARAMETER, /* parameter value in EXECUTE */ EXPR_KIND_TRIGGER_WHEN, /* WHEN condition in CREATE TRIGGER */ EXPR_KIND_POLICY, /* USING or WITH CHECK expr in policy */ - EXPR_KIND_PARTITION_EXPRESSION /* PARTITION BY expression */ + EXPR_KIND_PARTITION_EXPRESSION /* PARTITION BY expression */ } ParseExprKind; @@ -80,8 +80,8 @@ typedef Node *(*PreParseColumnRefHook) (ParseState *pstate, ColumnRef *cref); typedef Node *(*PostParseColumnRefHook) (ParseState *pstate, ColumnRef *cref, Node *var); typedef Node *(*ParseParamRefHook) (ParseState *pstate, ParamRef *pref); typedef Node *(*CoerceParamHook) (ParseState *pstate, Param *param, - Oid targetTypeId, int32 targetTypeMod, - int location); + Oid targetTypeId, int32 targetTypeMod, + int location); /* @@ -167,7 +167,7 @@ typedef Node *(*CoerceParamHook) (ParseState *pstate, Param *param, */ struct ParseState { - struct ParseState *parentParseState; /* stack link */ + struct ParseState *parentParseState; /* stack link */ const char *p_sourcetext; /* source text, or NULL if not available */ List *p_rtable; /* range table so far */ List *p_joinexprs; /* JoinExprs for RTE_JOIN p_rtable entries */ @@ -175,25 +175,24 @@ struct ParseState * node's fromlist) */ List *p_namespace; /* currently-referenceable RTEs (List of * ParseNamespaceItem) */ - bool p_lateral_active; /* p_lateral_only items visible? */ + bool p_lateral_active; /* p_lateral_only items visible? */ List *p_ctenamespace; /* current namespace for common table exprs */ List *p_future_ctes; /* common table exprs not yet in namespace */ - CommonTableExpr *p_parent_cte; /* this query's containing CTE */ - Relation p_target_relation; /* INSERT/UPDATE/DELETE target rel */ - RangeTblEntry *p_target_rangetblentry; /* target rel's RTE */ + CommonTableExpr *p_parent_cte; /* this query's containing CTE */ + Relation p_target_relation; /* INSERT/UPDATE/DELETE target rel */ + RangeTblEntry *p_target_rangetblentry; /* target rel's RTE */ bool p_is_insert; /* process assignment like INSERT not UPDATE */ List *p_windowdefs; /* raw representations of window clauses */ ParseExprKind p_expr_kind; /* what kind of expression we're parsing */ int p_next_resno; /* next targetlist resno to assign */ List *p_multiassign_exprs; /* junk tlist entries for multiassign */ - List *p_locking_clause; /* raw FOR UPDATE/FOR SHARE info */ + List *p_locking_clause; /* raw FOR UPDATE/FOR SHARE info */ bool p_locked_from_parent; /* parent has marked this subquery * with FOR UPDATE/FOR SHARE */ - bool p_resolve_unknowns; /* resolve unknown-type SELECT outputs - * as type text */ + bool p_resolve_unknowns; /* resolve unknown-type SELECT outputs as + * type text */ - QueryEnvironment *p_queryEnv; /* curr env, incl refs to enclosing - * env */ + QueryEnvironment *p_queryEnv; /* curr env, incl refs to enclosing env */ /* Flags telling about things found in the query: */ bool p_hasAggs; @@ -212,7 +211,7 @@ struct ParseState PostParseColumnRefHook p_post_columnref_hook; ParseParamRefHook p_paramref_hook; CoerceParamHook p_coerce_param_hook; - void *p_ref_hook_state; /* common passthrough link for above */ + void *p_ref_hook_state; /* common passthrough link for above */ }; /* @@ -280,4 +279,4 @@ extern ArrayRef *transformArraySubscripts(ParseState *pstate, Node *assignFrom); extern Const *make_const(ParseState *pstate, Value *value, int location); -#endif /* PARSE_NODE_H */ +#endif /* PARSE_NODE_H */ diff --git a/src/include/parser/parse_oper.h b/src/include/parser/parse_oper.h index ab3c4aa62f..3cab732b1f 100644 --- a/src/include/parser/parse_oper.h +++ b/src/include/parser/parse_oper.h @@ -64,4 +64,4 @@ extern Expr *make_scalar_array_op(ParseState *pstate, List *opname, bool useOr, Node *ltree, Node *rtree, int location); -#endif /* PARSE_OPER_H */ +#endif /* PARSE_OPER_H */ diff --git a/src/include/parser/parse_param.h b/src/include/parser/parse_param.h index 68f3ddaffa..50c21cfc9d 100644 --- a/src/include/parser/parse_param.h +++ b/src/include/parser/parse_param.h @@ -22,4 +22,4 @@ extern void parse_variable_parameters(ParseState *pstate, extern void check_variable_parameters(ParseState *pstate, Query *query); extern bool query_contains_extern_params(Query *query); -#endif /* PARSE_PARAM_H */ +#endif /* PARSE_PARAM_H */ diff --git a/src/include/parser/parse_relation.h b/src/include/parser/parse_relation.h index 4eece2bf8d..bbb605c31b 100644 --- a/src/include/parser/parse_relation.h +++ b/src/include/parser/parse_relation.h @@ -117,7 +117,7 @@ extern void addRTEtoQuery(ParseState *pstate, RangeTblEntry *rte, bool addToRelNameSpace, bool addToVarNameSpace); extern void errorMissingRTE(ParseState *pstate, RangeVar *relation) pg_attribute_noreturn(); extern void errorMissingColumn(ParseState *pstate, - char *relname, char *colname, int location) pg_attribute_noreturn(); + char *relname, char *colname, int location) pg_attribute_noreturn(); extern void expandRTE(RangeTblEntry *rte, int rtindex, int sublevels_up, int location, bool include_dropped, List **colnames, List **colvars); @@ -133,4 +133,4 @@ extern bool isQueryUsingTempRelation(Query *query); extern int specialAttNum(const char *attname); #endif -#endif /* PARSE_RELATION_H */ +#endif /* PARSE_RELATION_H */ diff --git a/src/include/parser/parse_target.h b/src/include/parser/parse_target.h index d06a235df0..44af46b1aa 100644 --- a/src/include/parser/parse_target.h +++ b/src/include/parser/parse_target.h @@ -43,4 +43,4 @@ extern TupleDesc expandRecordVariable(ParseState *pstate, Var *var, extern char *FigureColname(Node *node); extern char *FigureIndexColname(Node *node); -#endif /* PARSE_TARGET_H */ +#endif /* PARSE_TARGET_H */ diff --git a/src/include/parser/parse_type.h b/src/include/parser/parse_type.h index db0cd56ecc..7b843d0b9d 100644 --- a/src/include/parser/parse_type.h +++ b/src/include/parser/parse_type.h @@ -52,4 +52,4 @@ extern void parseTypeString(const char *str, Oid *typeid_p, int32 *typmod_p, boo #define ISCOMPLEX(typeid) (typeidTypeRelid(typeid) != InvalidOid) -#endif /* PARSE_TYPE_H */ +#endif /* PARSE_TYPE_H */ diff --git a/src/include/parser/parse_utilcmd.h b/src/include/parser/parse_utilcmd.h index c3cdf7158c..bae44d924f 100644 --- a/src/include/parser/parse_utilcmd.h +++ b/src/include/parser/parse_utilcmd.h @@ -38,4 +38,4 @@ extern bool CheckLocalIndexColumn (char loctype, char *partcolname, char *indexc extern PartitionBoundSpec *transformPartitionBound(ParseState *pstate, Relation parent, PartitionBoundSpec *spec); -#endif /* PARSE_UTILCMD_H */ +#endif /* PARSE_UTILCMD_H */ diff --git a/src/include/parser/parser.h b/src/include/parser/parser.h index c8ad710dac..8370df6bbb 100644 --- a/src/include/parser/parser.h +++ b/src/include/parser/parser.h @@ -23,7 +23,7 @@ typedef enum BACKSLASH_QUOTE_OFF, BACKSLASH_QUOTE_ON, BACKSLASH_QUOTE_SAFE_ENCODING -} BackslashQuoteType; +} BackslashQuoteType; /* GUC variables in scan.l (every one of these is a bad idea :-() */ extern int backslash_quote; @@ -38,4 +38,4 @@ extern List *raw_parser(const char *str); extern List *SystemFuncName(char *name); extern TypeName *SystemTypeName(char *name); -#endif /* PARSER_H */ +#endif /* PARSER_H */ diff --git a/src/include/parser/parsetree.h b/src/include/parser/parsetree.h index 951ff0a254..96cb2e2f67 100644 --- a/src/include/parser/parsetree.h +++ b/src/include/parser/parsetree.h @@ -76,4 +76,4 @@ extern TargetEntry *get_tle_by_resno(List *tlist, AttrNumber resno); extern RowMarkClause *get_parse_rowmark(Query *qry, Index rtindex); -#endif /* PARSETREE_H */ +#endif /* PARSETREE_H */ diff --git a/src/include/parser/scanner.h b/src/include/parser/scanner.h index 74f1cc897f..bb95de730b 100644 --- a/src/include/parser/scanner.h +++ b/src/include/parser/scanner.h @@ -127,4 +127,4 @@ extern int core_yylex(core_YYSTYPE *lvalp, YYLTYPE *llocp, extern int scanner_errposition(int location, core_yyscan_t yyscanner); extern void scanner_yyerror(const char *message, core_yyscan_t yyscanner) pg_attribute_noreturn(); -#endif /* SCANNER_H */ +#endif /* SCANNER_H */ diff --git a/src/include/parser/scansup.h b/src/include/parser/scansup.h index 3464eb4c0e..f9a36b5cbd 100644 --- a/src/include/parser/scansup.h +++ b/src/include/parser/scansup.h @@ -27,4 +27,4 @@ extern void truncate_identifier(char *ident, int len, bool warn); extern bool scanner_isspace(char ch); -#endif /* SCANSUP_H */ +#endif /* SCANSUP_H */ diff --git a/src/include/pg_config.h.win32 b/src/include/pg_config.h.win32 index f920e35664..d7cd0ac4f6 100644 --- a/src/include/pg_config.h.win32 +++ b/src/include/pg_config.h.win32 @@ -457,6 +457,9 @@ /* Define to 1 if you have the external array `tzname'. */ /* #undef HAVE_TZNAME */ +/* Define to 1 if you have the `ucol_strcollUTF8' function. */ +#define HAVE_UCOL_STRCOLLUTF8 1 + /* Define to 1 if the system has the type `uint64'. */ /* #undef HAVE_UINT64 */ diff --git a/src/include/pg_getopt.h b/src/include/pg_getopt.h index 2e25576499..16d5a326f9 100644 --- a/src/include/pg_getopt.h +++ b/src/include/pg_getopt.h @@ -29,7 +29,7 @@ extern int optind; extern int opterr; extern int optopt; -#endif /* HAVE_GETOPT_H */ +#endif /* HAVE_GETOPT_H */ /* * Some platforms have optreset but fail to declare it in <getopt.h>, so cope. @@ -40,7 +40,7 @@ extern int optreset; #endif #ifndef HAVE_GETOPT -extern int getopt(int nargc, char *const * nargv, const char *ostr); +extern int getopt(int nargc, char *const *nargv, const char *ostr); #endif -#endif /* PG_GETOPT_H */ +#endif /* PG_GETOPT_H */ diff --git a/src/include/pg_trace.h b/src/include/pg_trace.h index 1fe95e6403..29bc95d0d3 100644 --- a/src/include/pg_trace.h +++ b/src/include/pg_trace.h @@ -14,4 +14,4 @@ #include "utils/probes.h" /* pgrminclude ignore */ -#endif /* PG_TRACE_H */ +#endif /* PG_TRACE_H */ diff --git a/src/include/pgstat.h b/src/include/pgstat.h index ca40c572db..25dbf0dc12 100644 --- a/src/include/pgstat.h +++ b/src/include/pgstat.h @@ -40,7 +40,7 @@ typedef enum TrackFunctionsLevel TRACK_FUNC_OFF, TRACK_FUNC_PL, TRACK_FUNC_ALL -} TrackFunctionsLevel; +} TrackFunctionsLevel; /* ---------- * The types of backend -> collector messages @@ -155,7 +155,7 @@ typedef struct PgStat_TableStatus { Oid t_id; /* table's OID */ bool t_shared; /* is it a shared catalog? */ - struct PgStat_TableXactStatus *trans; /* lowest subxact's counts */ + struct PgStat_TableXactStatus *trans; /* lowest subxact's counts */ PgStat_TableCounts t_counts; /* event counts to be sent */ } PgStat_TableStatus; @@ -165,19 +165,19 @@ typedef struct PgStat_TableStatus */ typedef struct PgStat_TableXactStatus { - PgStat_Counter tuples_inserted; /* tuples inserted in (sub)xact */ - PgStat_Counter tuples_updated; /* tuples updated in (sub)xact */ - PgStat_Counter tuples_deleted; /* tuples deleted in (sub)xact */ + PgStat_Counter tuples_inserted; /* tuples inserted in (sub)xact */ + PgStat_Counter tuples_updated; /* tuples updated in (sub)xact */ + PgStat_Counter tuples_deleted; /* tuples deleted in (sub)xact */ bool truncated; /* relation truncated in this (sub)xact */ PgStat_Counter inserted_pre_trunc; /* tuples inserted prior to truncate */ PgStat_Counter updated_pre_trunc; /* tuples updated prior to truncate */ PgStat_Counter deleted_pre_trunc; /* tuples deleted prior to truncate */ int nest_level; /* subtransaction nest level */ /* links to other structs for same relation: */ - struct PgStat_TableXactStatus *upper; /* next higher subxact if any */ + struct PgStat_TableXactStatus *upper; /* next higher subxact if any */ PgStat_TableStatus *parent; /* per-table status */ /* structs of same subxact level are linked here: */ - struct PgStat_TableXactStatus *next; /* next of same subxact */ + struct PgStat_TableXactStatus *next; /* next of same subxact */ } PgStat_TableXactStatus; @@ -419,7 +419,7 @@ typedef struct PgStat_MsgBgWriter PgStat_Counter m_buf_written_backend; PgStat_Counter m_buf_fsync_backend; PgStat_Counter m_buf_alloc; - PgStat_Counter m_checkpoint_write_time; /* times in milliseconds */ + PgStat_Counter m_checkpoint_write_time; /* times in milliseconds */ PgStat_Counter m_checkpoint_sync_time; } PgStat_MsgBgWriter; @@ -634,13 +634,13 @@ typedef struct PgStat_StatTabEntry PgStat_Counter blocks_fetched; PgStat_Counter blocks_hit; - TimestampTz vacuum_timestamp; /* user initiated vacuum */ + TimestampTz vacuum_timestamp; /* user initiated vacuum */ PgStat_Counter vacuum_count; - TimestampTz autovac_vacuum_timestamp; /* autovacuum initiated */ + TimestampTz autovac_vacuum_timestamp; /* autovacuum initiated */ PgStat_Counter autovac_vacuum_count; - TimestampTz analyze_timestamp; /* user initiated */ + TimestampTz analyze_timestamp; /* user initiated */ PgStat_Counter analyze_count; - TimestampTz autovac_analyze_timestamp; /* autovacuum initiated */ + TimestampTz autovac_analyze_timestamp; /* autovacuum initiated */ PgStat_Counter autovac_analyze_count; } PgStat_StatTabEntry; @@ -665,13 +665,13 @@ typedef struct PgStat_StatFuncEntry */ typedef struct PgStat_ArchiverStats { - PgStat_Counter archived_count; /* archival successes */ + PgStat_Counter archived_count; /* archival successes */ char last_archived_wal[MAX_XFN_CHARS + 1]; /* last WAL file * archived */ - TimestampTz last_archived_timestamp; /* last archival success time */ + TimestampTz last_archived_timestamp; /* last archival success time */ PgStat_Counter failed_count; /* failed archival attempts */ - char last_failed_wal[MAX_XFN_CHARS + 1]; /* WAL file involved in - * last failure */ + char last_failed_wal[MAX_XFN_CHARS + 1]; /* WAL file involved in + * last failure */ TimestampTz last_failed_timestamp; /* last archival failure time */ TimestampTz stat_reset_timestamp; } PgStat_ArchiverStats; @@ -684,7 +684,7 @@ typedef struct PgStat_GlobalStats TimestampTz stats_timestamp; /* time of stats file update */ PgStat_Counter timed_checkpoints; PgStat_Counter requested_checkpoints; - PgStat_Counter checkpoint_write_time; /* times in milliseconds */ + PgStat_Counter checkpoint_write_time; /* times in milliseconds */ PgStat_Counter checkpoint_sync_time; PgStat_Counter buf_written_checkpoints; PgStat_Counter buf_written_clean; @@ -938,9 +938,9 @@ typedef struct PgBackendSSLStatus /* Information about SSL connection */ int ssl_bits; bool ssl_compression; - char ssl_version[NAMEDATALEN]; /* MUST be null-terminated */ - char ssl_cipher[NAMEDATALEN]; /* MUST be null-terminated */ - char ssl_clientdn[NAMEDATALEN]; /* MUST be null-terminated */ + char ssl_version[NAMEDATALEN]; /* MUST be null-terminated */ + char ssl_cipher[NAMEDATALEN]; /* MUST be null-terminated */ + char ssl_clientdn[NAMEDATALEN]; /* MUST be null-terminated */ } PgBackendSSLStatus; @@ -991,7 +991,7 @@ typedef struct PgBackendStatus Oid st_databaseid; Oid st_userid; SockAddr st_clientaddr; - char *st_clienthostname; /* MUST be null-terminated */ + char *st_clienthostname; /* MUST be null-terminated */ /* Information about SSL connection */ bool st_ssl; @@ -1333,4 +1333,4 @@ extern int pgstat_fetch_stat_numbackends(void); extern PgStat_ArchiverStats *pgstat_fetch_stat_archiver(void); extern PgStat_GlobalStats *pgstat_fetch_global(void); -#endif /* PGSTAT_H */ +#endif /* PGSTAT_H */ diff --git a/src/include/pgtar.h b/src/include/pgtar.h index d0188efaa6..9a1be4c9f6 100644 --- a/src/include/pgtar.h +++ b/src/include/pgtar.h @@ -20,7 +20,7 @@ enum tarError }; extern enum tarError tarCreateHeader(char *h, const char *filename, const char *linktarget, - pgoff_t size, mode_t mode, uid_t uid, gid_t gid, time_t mtime); + pgoff_t size, mode_t mode, uid_t uid, gid_t gid, time_t mtime); extern uint64 read_tar_number(const char *s, int len); extern void print_tar_number(char *s, int len, uint64 val); extern int tarChecksum(char *header); diff --git a/src/include/pgtime.h b/src/include/pgtime.h index 52b54b920a..4fd8f75ef9 100644 --- a/src/include/pgtime.h +++ b/src/include/pgtime.h @@ -66,7 +66,7 @@ extern bool pg_tz_acceptable(pg_tz *tz); /* these functions are in strftime.c */ extern size_t pg_strftime(char *s, size_t max, const char *format, - const struct pg_tm * tm); + const struct pg_tm *tm); /* these functions and variables are in pgtz.c */ @@ -81,4 +81,4 @@ extern pg_tzenum *pg_tzenumerate_start(void); extern pg_tz *pg_tzenumerate_next(pg_tzenum *dir); extern void pg_tzenumerate_end(pg_tzenum *dir); -#endif /* _PGTIME_H */ +#endif /* _PGTIME_H */ diff --git a/src/include/port.h b/src/include/port.h index 7d8e8a68d4..3729b7a306 100644 --- a/src/include/port.h +++ b/src/include/port.h @@ -180,7 +180,7 @@ extern int pg_printf(const char *fmt,...) pg_attribute_printf(1, 2); #define fprintf pg_fprintf #define printf pg_printf #endif -#endif /* USE_REPL_SNPRINTF */ +#endif /* USE_REPL_SNPRINTF */ #if defined(WIN32) /* @@ -200,7 +200,7 @@ extern int pg_printf(const char *fmt,...) pg_attribute_printf(1, 2); extern char *pgwin32_setlocale(int category, const char *locale); #define setlocale(a,b) pgwin32_setlocale(a,b) -#endif /* WIN32 */ +#endif /* WIN32 */ /* Portable prompt handling */ extern void simple_prompt(const char *prompt, char *destination, size_t destlen, @@ -237,7 +237,7 @@ extern int pgunlink(const char *path); #define rename(from, to) pgrename(from, to) #define unlink(path) pgunlink(path) -#endif /* defined(WIN32) || defined(__CYGWIN__) */ +#endif /* defined(WIN32) || defined(__CYGWIN__) */ /* * Win32 also doesn't have symlinks, but we can emulate them with @@ -271,7 +271,7 @@ extern bool rmtree(const char *path, bool rmtopdir); */ #if defined(WIN32) && !defined(__CYGWIN__) && !defined(UNSAFE_STAT_OK) #include <sys/stat.h> -extern int pgwin32_safestat(const char *path, struct stat * buf); +extern int pgwin32_safestat(const char *path, struct stat *buf); #define stat(a,b) pgwin32_safestat(a,b) #endif @@ -317,7 +317,7 @@ extern FILE *pgwin32_popen(const char *command, const char *type); /* New versions of MingW have gettimeofday, old mingw and msvc don't */ #ifndef HAVE_GETTIMEOFDAY /* Last parameter not used */ -extern int gettimeofday(struct timeval * tp, struct timezone * tzp); +extern int gettimeofday(struct timeval *tp, struct timezone *tzp); #endif #else /* !WIN32 */ @@ -326,7 +326,7 @@ extern int gettimeofday(struct timeval * tp, struct timezone * tzp); * close() does them all. */ #define closesocket close -#endif /* WIN32 */ +#endif /* WIN32 */ /* * On Windows, setvbuf() does not support _IOLBF mode, and interprets that @@ -392,7 +392,7 @@ extern double rint(double x); #ifndef HAVE_INET_ATON #include <netinet/in.h> #include <arpa/inet.h> -extern int inet_aton(const char *cp, struct in_addr * addr); +extern int inet_aton(const char *cp, struct in_addr *addr); #endif #if !HAVE_DECL_STRLCAT @@ -423,14 +423,14 @@ extern void srandom(unsigned int seed); extern char *pqStrerror(int errnum, char *strerrbuf, size_t buflen); #ifndef WIN32 -extern int pqGetpwuid(uid_t uid, struct passwd * resultbuf, char *buffer, - size_t buflen, struct passwd ** result); +extern int pqGetpwuid(uid_t uid, struct passwd *resultbuf, char *buffer, + size_t buflen, struct passwd **result); #endif extern int pqGethostbyname(const char *name, - struct hostent * resultbuf, + struct hostent *resultbuf, char *buffer, size_t buflen, - struct hostent ** result, + struct hostent **result, int *herrno); extern void pg_qsort(void *base, size_t nel, size_t elsize, @@ -485,4 +485,4 @@ extern char *escape_single_quotes_ascii(const char *src); /* port/wait_error.c */ extern char *wait_result_to_str(int exit_status); -#endif /* PG_PORT_H */ +#endif /* PG_PORT_H */ diff --git a/src/include/port/atomics.h b/src/include/port/atomics.h index 89eb522637..2bfd1ed728 100644 --- a/src/include/port/atomics.h +++ b/src/include/port/atomics.h @@ -532,4 +532,4 @@ pg_atomic_sub_fetch_u64(volatile pg_atomic_uint64 *ptr, int64 sub_) #undef INSIDE_ATOMICS_H -#endif /* ATOMICS_H */ +#endif /* ATOMICS_H */ diff --git a/src/include/port/pg_bswap.h b/src/include/port/pg_bswap.h index 18859a6ea3..50a6bd106b 100644 --- a/src/include/port/pg_bswap.h +++ b/src/include/port/pg_bswap.h @@ -29,7 +29,7 @@ (((x) << 8) & 0x00ff0000) | \ (((x) >> 8) & 0x0000ff00) | \ (((x) >> 24) & 0x000000ff)) -#endif /* HAVE__BUILTIN_BSWAP32 */ +#endif /* HAVE__BUILTIN_BSWAP32 */ #ifdef HAVE__BUILTIN_BSWAP64 #define BSWAP64(x) __builtin_bswap64(x) @@ -42,7 +42,7 @@ (((x) >> 24) & UINT64CONST(0x0000000000ff0000)) | \ (((x) >> 40) & UINT64CONST(0x000000000000ff00)) | \ (((x) >> 56) & UINT64CONST(0x00000000000000ff))) -#endif /* HAVE__BUILTIN_BSWAP64 */ +#endif /* HAVE__BUILTIN_BSWAP64 */ /* * Rearrange the bytes of a Datum from big-endian order into the native byte @@ -63,7 +63,7 @@ #define DatumBigEndianToNative(x) BSWAP64(x) #else /* SIZEOF_DATUM != 8 */ #define DatumBigEndianToNative(x) BSWAP32(x) -#endif /* SIZEOF_DATUM == 8 */ -#endif /* WORDS_BIGENDIAN */ +#endif /* SIZEOF_DATUM == 8 */ +#endif /* WORDS_BIGENDIAN */ -#endif /* PG_BSWAP_H */ +#endif /* PG_BSWAP_H */ diff --git a/src/include/port/pg_crc32c.h b/src/include/port/pg_crc32c.h index aa35fa89d2..cd58ecc988 100644 --- a/src/include/port/pg_crc32c.h +++ b/src/include/port/pg_crc32c.h @@ -82,4 +82,4 @@ extern pg_crc32c pg_comp_crc32c_sb8(pg_crc32c crc, const void *data, size_t len) #endif -#endif /* PG_CRC32C_H */ +#endif /* PG_CRC32C_H */ diff --git a/src/include/port/win32.h b/src/include/port/win32.h index 0debb3b3f4..23f89748ac 100644 --- a/src/include/port/win32.h +++ b/src/include/port/win32.h @@ -222,7 +222,7 @@ struct itimerval struct timeval it_value; }; -int setitimer(int which, const struct itimerval * value, struct itimerval * ovalue); +int setitimer(int which, const struct itimerval *value, struct itimerval *ovalue); /* * WIN32 does not provide 64-bit off_t, but does provide the functions operating @@ -376,11 +376,11 @@ void pg_queue_signal(int signum); #define send(s, buf, len, flags) pgwin32_send(s, buf, len, flags) SOCKET pgwin32_socket(int af, int type, int protocol); -int pgwin32_bind(SOCKET s, struct sockaddr * addr, int addrlen); +int pgwin32_bind(SOCKET s, struct sockaddr *addr, int addrlen); int pgwin32_listen(SOCKET s, int backlog); -SOCKET pgwin32_accept(SOCKET s, struct sockaddr * addr, int *addrlen); -int pgwin32_connect(SOCKET s, const struct sockaddr * name, int namelen); -int pgwin32_select(int nfds, fd_set *readfs, fd_set *writefds, fd_set *exceptfds, const struct timeval * timeout); +SOCKET pgwin32_accept(SOCKET s, struct sockaddr *addr, int *addrlen); +int pgwin32_connect(SOCKET s, const struct sockaddr *name, int namelen); +int pgwin32_select(int nfds, fd_set *readfs, fd_set *writefds, fd_set *exceptfds, const struct timeval *timeout); int pgwin32_recv(SOCKET s, char *buf, int len, int flags); int pgwin32_send(SOCKET s, const void *buf, int len, int flags); @@ -442,7 +442,7 @@ typedef unsigned short mode_t; /* Pulled from Makefile.port in mingw */ #define DLSUFFIX ".dll" -#endif /* _MSC_VER */ +#endif /* _MSC_VER */ /* These aren't provided by either MingW or MSVC */ #define S_IRGRP 0 diff --git a/src/include/port/win32/sys/socket.h b/src/include/port/win32/sys/socket.h index edaee6a894..9b2cdf3b9b 100644 --- a/src/include/port/win32/sys/socket.h +++ b/src/include/port/win32/sys/socket.h @@ -30,4 +30,4 @@ */ #undef gai_strerror -#endif /* WIN32_SYS_SOCKET_H */ +#endif /* WIN32_SYS_SOCKET_H */ diff --git a/src/include/portability/instr_time.h b/src/include/portability/instr_time.h index 9eb4bb7eac..b6e8c58d44 100644 --- a/src/include/portability/instr_time.h +++ b/src/include/portability/instr_time.h @@ -202,7 +202,7 @@ typedef struct timeval instr_time; #define INSTR_TIME_GET_MICROSEC(t) \ (((uint64) (t).tv_sec * (uint64) 1000000) + (uint64) (t).tv_usec) -#endif /* HAVE_CLOCK_GETTIME */ +#endif /* HAVE_CLOCK_GETTIME */ #else /* WIN32 */ @@ -243,6 +243,6 @@ GetTimerFrequency(void) return (double) f.QuadPart; } -#endif /* WIN32 */ +#endif /* WIN32 */ -#endif /* INSTR_TIME_H */ +#endif /* INSTR_TIME_H */ diff --git a/src/include/portability/mem.h b/src/include/portability/mem.h index d560c3ce56..fa507c2581 100644 --- a/src/include/portability/mem.h +++ b/src/include/portability/mem.h @@ -45,4 +45,4 @@ #define MAP_FAILED ((void *) -1) #endif -#endif /* MEM_H */ +#endif /* MEM_H */ diff --git a/src/include/postgres.h b/src/include/postgres.h index 7426a253d2..29eec53bf8 100644 --- a/src/include/postgres.h +++ b/src/include/postgres.h @@ -81,7 +81,7 @@ typedef struct varatt_external int32 va_extsize; /* External saved size (doesn't) */ Oid va_valueid; /* Unique ID of value within TOAST table */ Oid va_toastrelid; /* RelID of TOAST table containing it */ -} varatt_external; +} varatt_external; /* * struct varatt_indirect is a "TOAST pointer" representing an out-of-line @@ -95,7 +95,7 @@ typedef struct varatt_external typedef struct varatt_indirect { struct varlena *pointer; /* Pointer to in-memory varlena */ -} varatt_indirect; +} varatt_indirect; /* * struct varatt_expanded is a "TOAST pointer" representing an out-of-line @@ -157,7 +157,7 @@ typedef union { uint32 va_header; uint32 va_rawsize; /* Original data size (excludes header) */ - char va_data[FLEXIBLE_ARRAY_MEMBER]; /* Compressed data */ + char va_data[FLEXIBLE_ARRAY_MEMBER]; /* Compressed data */ } va_compressed; } varattrib_4b; @@ -274,7 +274,7 @@ typedef struct #define SET_VARTAG_1B_E(PTR,tag) \ (((varattrib_1b_e *) (PTR))->va_header = 0x01, \ ((varattrib_1b_e *) (PTR))->va_tag = (tag)) -#endif /* WORDS_BIGENDIAN */ +#endif /* WORDS_BIGENDIAN */ #define VARHDRSZ_SHORT offsetof(varattrib_1b, va_data) #define VARATT_SHORT_MAX 0x7F @@ -811,10 +811,7 @@ extern Datum Float8GetDatum(float8 X); */ extern void ExceptionalCondition(const char *conditionName, const char *errorType, - const char *fileName, int lineNumber) pg_attribute_noreturn(); - -//#define PGXC_COORD // for PGXC coordinator compiling -//#define PGXC_DATANODE // for PGXC data node compiling + const char *fileName, int lineNumber) pg_attribute_noreturn(); extern void ResetUsageCommon(struct rusage *save_r, struct timeval *save_t); @@ -822,4 +819,4 @@ extern void ResetUsage(void); extern void ShowUsageCommon(const char *title, struct rusage *save_r, struct timeval *save_t); -#endif /* POSTGRES_H */ +#endif /* POSTGRES_H */ diff --git a/src/include/postgres_ext.h b/src/include/postgres_ext.h index 452eae9935..fdb61b7cf5 100644 --- a/src/include/postgres_ext.h +++ b/src/include/postgres_ext.h @@ -71,4 +71,4 @@ typedef PG_INT64_TYPE pg_int64; #define PG_DIAG_SOURCE_LINE 'L' #define PG_DIAG_SOURCE_FUNCTION 'R' -#endif /* POSTGRES_EXT_H */ +#endif /* POSTGRES_EXT_H */ diff --git a/src/include/postgres_fe.h b/src/include/postgres_fe.h index f49e33bc35..1dd01d0283 100644 --- a/src/include/postgres_fe.h +++ b/src/include/postgres_fe.h @@ -26,4 +26,4 @@ #include "common/fe_memutils.h" -#endif /* POSTGRES_FE_H */ +#endif /* POSTGRES_FE_H */ diff --git a/src/include/postmaster/autovacuum.h b/src/include/postmaster/autovacuum.h index e61cc93e55..5ce7f62739 100644 --- a/src/include/postmaster/autovacuum.h +++ b/src/include/postmaster/autovacuum.h @@ -84,4 +84,4 @@ extern void AutoVacuumRequestWork(AutoVacuumWorkItemType type, extern Size AutoVacuumShmemSize(void); extern void AutoVacuumShmemInit(void); -#endif /* AUTOVACUUM_H */ +#endif /* AUTOVACUUM_H */ diff --git a/src/include/postmaster/bgworker.h b/src/include/postmaster/bgworker.h index 51a5978ea8..e2ecd3c9eb 100644 --- a/src/include/postmaster/bgworker.h +++ b/src/include/postmaster/bgworker.h @@ -90,7 +90,7 @@ typedef struct BackgroundWorker char bgw_name[BGW_MAXLEN]; int bgw_flags; BgWorkerStartTime bgw_start_time; - int bgw_restart_time; /* in seconds, or BGW_NEVER_RESTART */ + int bgw_restart_time; /* in seconds, or BGW_NEVER_RESTART */ char bgw_library_name[BGW_MAXLEN]; char bgw_function_name[BGW_MAXLEN]; Datum bgw_main_arg; @@ -119,9 +119,7 @@ extern bool RegisterDynamicBackgroundWorker(BackgroundWorker *worker, /* Query the status of a bgworker */ extern BgwHandleStatus GetBackgroundWorkerPid(BackgroundWorkerHandle *handle, pid_t *pidp); -extern BgwHandleStatus -WaitForBackgroundWorkerStartup(BackgroundWorkerHandle * - handle, pid_t *pid); +extern BgwHandleStatus WaitForBackgroundWorkerStartup(BackgroundWorkerHandle *handle, pid_t *pid); extern BgwHandleStatus WaitForBackgroundWorkerShutdown(BackgroundWorkerHandle *); @@ -149,4 +147,4 @@ extern void BackgroundWorkerInitializeConnectionByOid(Oid dboid, Oid useroid); extern void BackgroundWorkerBlockSignals(void); extern void BackgroundWorkerUnblockSignals(void); -#endif /* BGWORKER_H */ +#endif /* BGWORKER_H */ diff --git a/src/include/postmaster/bgworker_internals.h b/src/include/postmaster/bgworker_internals.h index 9e0b0621cf..bff10ba53c 100644 --- a/src/include/postmaster/bgworker_internals.h +++ b/src/include/postmaster/bgworker_internals.h @@ -60,4 +60,4 @@ extern void StartBackgroundWorker(void) pg_attribute_noreturn(); extern BackgroundWorker *BackgroundWorkerEntry(int slotno); #endif -#endif /* BGWORKER_INTERNALS_H */ +#endif /* BGWORKER_INTERNALS_H */ diff --git a/src/include/postmaster/bgwriter.h b/src/include/postmaster/bgwriter.h index 359b3ef5a5..a9b8bc7e8e 100644 --- a/src/include/postmaster/bgwriter.h +++ b/src/include/postmaster/bgwriter.h @@ -40,4 +40,4 @@ extern void CheckpointerShmemInit(void); extern bool FirstCallSinceLastCheckpoint(void); -#endif /* _BGWRITER_H */ +#endif /* _BGWRITER_H */ diff --git a/src/include/postmaster/fork_process.h b/src/include/postmaster/fork_process.h index c2bfd44ea0..9d5b97aca7 100644 --- a/src/include/postmaster/fork_process.h +++ b/src/include/postmaster/fork_process.h @@ -14,4 +14,4 @@ extern pid_t fork_process(void); -#endif /* FORK_PROCESS_H */ +#endif /* FORK_PROCESS_H */ diff --git a/src/include/postmaster/pgarch.h b/src/include/postmaster/pgarch.h index 6a4e0f43b8..ab1ddcf52c 100644 --- a/src/include/postmaster/pgarch.h +++ b/src/include/postmaster/pgarch.h @@ -36,4 +36,4 @@ extern int pgarch_start(void); extern void PgArchiverMain(int argc, char *argv[]) pg_attribute_noreturn(); #endif -#endif /* _PGARCH_H */ +#endif /* _PGARCH_H */ diff --git a/src/include/postmaster/postmaster.h b/src/include/postmaster/postmaster.h index 95231bf768..0f85908b09 100644 --- a/src/include/postmaster/postmaster.h +++ b/src/include/postmaster/postmaster.h @@ -39,9 +39,9 @@ extern int postmaster_alive_fds[2]; * Constants that represent which of postmaster_alive_fds is held by * postmaster, and which is used in children to check for postmaster death. */ -#define POSTMASTER_FD_WATCH 0 /* used in children to check for - * postmaster death */ -#define POSTMASTER_FD_OWN 1 /* kept open by postmaster only */ +#define POSTMASTER_FD_WATCH 0 /* used in children to check for + * postmaster death */ +#define POSTMASTER_FD_OWN 1 /* kept open by postmaster only */ #endif extern const char *progname; @@ -74,4 +74,4 @@ extern void ShmemBackendArrayAllocation(void); */ #define MAX_BACKENDS 0x3FFFF -#endif /* _POSTMASTER_H */ +#endif /* _POSTMASTER_H */ diff --git a/src/include/postmaster/startup.h b/src/include/postmaster/startup.h index ce76d94991..883bd395bd 100644 --- a/src/include/postmaster/startup.h +++ b/src/include/postmaster/startup.h @@ -19,4 +19,4 @@ extern void PostRestoreCommand(void); extern bool IsPromoteTriggered(void); extern void ResetPromoteTriggered(void); -#endif /* _STARTUP_H */ +#endif /* _STARTUP_H */ diff --git a/src/include/postmaster/syslogger.h b/src/include/postmaster/syslogger.h index 94d7eac347..f4248ef5d4 100644 --- a/src/include/postmaster/syslogger.h +++ b/src/include/postmaster/syslogger.h @@ -94,4 +94,4 @@ extern void SysLoggerMain(int argc, char *argv[]) pg_attribute_noreturn(); #define LOG_METAINFO_DATAFILE "current_logfiles" #define LOG_METAINFO_DATAFILE_TMP LOG_METAINFO_DATAFILE ".tmp" -#endif /* _SYSLOGGER_H */ +#endif /* _SYSLOGGER_H */ diff --git a/src/include/postmaster/walwriter.h b/src/include/postmaster/walwriter.h index fb91385e0b..f0eb425802 100644 --- a/src/include/postmaster/walwriter.h +++ b/src/include/postmaster/walwriter.h @@ -18,4 +18,4 @@ extern int WalWriterFlushAfter; extern void WalWriterMain(void) pg_attribute_noreturn(); -#endif /* _WALWRITER_H */ +#endif /* _WALWRITER_H */ diff --git a/src/include/regex/regex.h b/src/include/regex/regex.h index cc73db2547..27fdc09040 100644 --- a/src/include/regex/regex.h +++ b/src/include/regex/regex.h @@ -173,4 +173,4 @@ extern int pg_regprefix(regex_t *, pg_wchar **, size_t *); extern void pg_regfree(regex_t *); extern size_t pg_regerror(int, const regex_t *, char *, size_t); -#endif /* _REGEX_H_ */ +#endif /* _REGEX_H_ */ diff --git a/src/include/regex/regexport.h b/src/include/regex/regexport.h index 091c568e63..1c84d15d55 100644 --- a/src/include/regex/regexport.h +++ b/src/include/regex/regexport.h @@ -54,4 +54,4 @@ extern int pg_reg_getnumcharacters(const regex_t *regex, int co); extern void pg_reg_getcharacters(const regex_t *regex, int co, pg_wchar *chars, int chars_len); -#endif /* _REGEXPORT_H_ */ +#endif /* _REGEXPORT_H_ */ diff --git a/src/include/regex/regguts.h b/src/include/regex/regguts.h index 69816f1449..5d0e7a961c 100644 --- a/src/include/regex/regguts.h +++ b/src/include/regex/regguts.h @@ -218,7 +218,7 @@ struct colormap color *locolormap; /* simple array indexed by chr code */ /* mapping data for chrs > MAX_SIMPLE_CHR: */ - int classbits[NUM_CCLASSES]; /* see comment above */ + int classbits[NUM_CCLASSES]; /* see comment above */ int numcmranges; /* number of colormapranges */ colormaprange *cmranges; /* ranges of high chrs */ color *hicolormap; /* 2-D array of color entries */ @@ -479,4 +479,4 @@ struct guts /* prototypes for functions that are exported from regcomp.c to regexec.c */ extern void pg_set_regex_collation(Oid collation); -extern color pg_reg_getcolor(struct colormap * cm, chr c); +extern color pg_reg_getcolor(struct colormap *cm, chr c); diff --git a/src/include/replication/basebackup.h b/src/include/replication/basebackup.h index bbd446904f..1a165c860b 100644 --- a/src/include/replication/basebackup.h +++ b/src/include/replication/basebackup.h @@ -33,4 +33,4 @@ extern void SendBaseBackup(BaseBackupCmd *cmd); extern int64 sendTablespace(char *path, bool sizeonly); -#endif /* _BASEBACKUP_H */ +#endif /* _BASEBACKUP_H */ diff --git a/src/include/replication/logical.h b/src/include/replication/logical.h index 159da7f23f..7f0e0fa881 100644 --- a/src/include/replication/logical.h +++ b/src/include/replication/logical.h @@ -18,18 +18,18 @@ struct LogicalDecodingContext; typedef void (*LogicalOutputPluginWriterWrite) ( - struct LogicalDecodingContext *lr, - XLogRecPtr Ptr, - TransactionId xid, - bool last_write + struct LogicalDecodingContext *lr, + XLogRecPtr Ptr, + TransactionId xid, + bool last_write ); typedef LogicalOutputPluginWriterWrite LogicalOutputPluginWriterPrepareWrite; typedef void (*LogicalOutputPluginWriterUpdateProgress) ( - struct LogicalDecodingContext *lr, - XLogRecPtr Ptr, - TransactionId xid + struct LogicalDecodingContext *lr, + XLogRecPtr Ptr, + TransactionId xid ); typedef struct LogicalDecodingContext @@ -93,14 +93,14 @@ extern LogicalDecodingContext *CreateInitDecodingContext(char *plugin, XLogPageReadCB read_page, LogicalOutputPluginWriterPrepareWrite prepare_write, LogicalOutputPluginWriterWrite do_write, - LogicalOutputPluginWriterUpdateProgress update_progress); + LogicalOutputPluginWriterUpdateProgress update_progress); extern LogicalDecodingContext *CreateDecodingContext( XLogRecPtr start_lsn, List *output_plugin_options, XLogPageReadCB read_page, LogicalOutputPluginWriterPrepareWrite prepare_write, LogicalOutputPluginWriterWrite do_write, - LogicalOutputPluginWriterUpdateProgress update_progress); + LogicalOutputPluginWriterUpdateProgress update_progress); extern void DecodingContextFindStartpoint(LogicalDecodingContext *ctx); extern bool DecodingContextReady(LogicalDecodingContext *ctx); extern void FreeDecodingContext(LogicalDecodingContext *ctx); diff --git a/src/include/replication/logicallauncher.h b/src/include/replication/logicallauncher.h index 4f3e89e061..aac7d326e2 100644 --- a/src/include/replication/logicallauncher.h +++ b/src/include/replication/logicallauncher.h @@ -26,4 +26,4 @@ extern void AtEOXact_ApplyLauncher(bool isCommit); extern bool IsLogicalLauncher(void); -#endif /* LOGICALLAUNCHER_H */ +#endif /* LOGICALLAUNCHER_H */ diff --git a/src/include/replication/logicalproto.h b/src/include/replication/logicalproto.h index e7679e29ed..191b03772f 100644 --- a/src/include/replication/logicalproto.h +++ b/src/include/replication/logicalproto.h @@ -103,4 +103,4 @@ extern LogicalRepRelation *logicalrep_read_rel(StringInfo in); extern void logicalrep_write_typ(StringInfo out, Oid typoid); extern void logicalrep_read_typ(StringInfo out, LogicalRepTyp *ltyp); -#endif /* LOGICALREP_PROTO_H */ +#endif /* LOGICALREP_PROTO_H */ diff --git a/src/include/replication/logicalrelation.h b/src/include/replication/logicalrelation.h index 3b814d3b2b..8352705650 100644 --- a/src/include/replication/logicalrelation.h +++ b/src/include/replication/logicalrelation.h @@ -16,7 +16,7 @@ typedef struct LogicalRepRelMapEntry { - LogicalRepRelation remoterel; /* key is remoterel.remoteid */ + LogicalRepRelation remoterel; /* key is remoterel.remoteid */ /* Mapping to local relation, filled as needed. */ Oid localreloid; /* local relation id */ @@ -39,4 +39,4 @@ extern void logicalrep_rel_close(LogicalRepRelMapEntry *rel, extern void logicalrep_typmap_update(LogicalRepTyp *remotetyp); extern Oid logicalrep_typmap_getid(Oid remoteid); -#endif /* LOGICALRELATION_H */ +#endif /* LOGICALRELATION_H */ diff --git a/src/include/replication/logicalworker.h b/src/include/replication/logicalworker.h index 5877a930f6..2557d5a23b 100644 --- a/src/include/replication/logicalworker.h +++ b/src/include/replication/logicalworker.h @@ -16,4 +16,4 @@ extern void ApplyWorkerMain(Datum main_arg); extern bool IsLogicalWorker(void); -#endif /* LOGICALWORKER_H */ +#endif /* LOGICALWORKER_H */ diff --git a/src/include/replication/message.h b/src/include/replication/message.h index b016af7bd7..1f2d0bb535 100644 --- a/src/include/replication/message.h +++ b/src/include/replication/message.h @@ -39,4 +39,4 @@ void logicalmsg_redo(XLogReaderState *record); void logicalmsg_desc(StringInfo buf, XLogReaderState *record); const char *logicalmsg_identify(uint8 info); -#endif /* PG_LOGICAL_MESSAGE_H */ +#endif /* PG_LOGICAL_MESSAGE_H */ diff --git a/src/include/replication/origin.h b/src/include/replication/origin.h index d6b8eb9d80..ca56c01469 100644 --- a/src/include/replication/origin.h +++ b/src/include/replication/origin.h @@ -71,4 +71,4 @@ const char *replorigin_identify(uint8 info); extern Size ReplicationOriginShmemSize(void); extern void ReplicationOriginShmemInit(void); -#endif /* PG_ORIGIN_H */ +#endif /* PG_ORIGIN_H */ diff --git a/src/include/replication/output_plugin.h b/src/include/replication/output_plugin.h index 2435e2be2d..26ff024882 100644 --- a/src/include/replication/output_plugin.h +++ b/src/include/replication/output_plugin.h @@ -42,47 +42,47 @@ typedef void (*LogicalOutputPluginInit) (struct OutputPluginCallbacks *cb); * the same slot is used from there one, it will be "false". */ typedef void (*LogicalDecodeStartupCB) (struct LogicalDecodingContext *ctx, - OutputPluginOptions *options, - bool is_init); + OutputPluginOptions *options, + bool is_init); /* * Callback called for every (explicit or implicit) BEGIN of a successful * transaction. */ typedef void (*LogicalDecodeBeginCB) (struct LogicalDecodingContext *ctx, - ReorderBufferTXN *txn); + ReorderBufferTXN *txn); /* * Callback for every individual change in a successful transaction. */ typedef void (*LogicalDecodeChangeCB) (struct LogicalDecodingContext *ctx, - ReorderBufferTXN *txn, - Relation relation, - ReorderBufferChange *change); + ReorderBufferTXN *txn, + Relation relation, + ReorderBufferChange *change); /* * Called for every (explicit or implicit) COMMIT of a successful transaction. */ typedef void (*LogicalDecodeCommitCB) (struct LogicalDecodingContext *ctx, - ReorderBufferTXN *txn, - XLogRecPtr commit_lsn); + ReorderBufferTXN *txn, + XLogRecPtr commit_lsn); /* * Called for the generic logical decoding messages. */ typedef void (*LogicalDecodeMessageCB) (struct LogicalDecodingContext *ctx, - ReorderBufferTXN *txn, - XLogRecPtr message_lsn, - bool transactional, - const char *prefix, - Size message_size, - const char *message); + ReorderBufferTXN *txn, + XLogRecPtr message_lsn, + bool transactional, + const char *prefix, + Size message_size, + const char *message); /* * Filter changes by origin. */ typedef bool (*LogicalDecodeFilterByOriginCB) (struct LogicalDecodingContext *ctx, - RepOriginId origin_id); + RepOriginId origin_id); /* * Called to shutdown an output plugin. @@ -108,4 +108,4 @@ extern void OutputPluginPrepareWrite(struct LogicalDecodingContext *ctx, bool la extern void OutputPluginWrite(struct LogicalDecodingContext *ctx, bool last_write); extern void OutputPluginUpdateProgress(struct LogicalDecodingContext *ctx); -#endif /* OUTPUT_PLUGIN_H */ +#endif /* OUTPUT_PLUGIN_H */ diff --git a/src/include/replication/pgoutput.h b/src/include/replication/pgoutput.h index 8cd29ab164..bfe8448ba9 100644 --- a/src/include/replication/pgoutput.h +++ b/src/include/replication/pgoutput.h @@ -27,4 +27,4 @@ typedef struct PGOutputData List *publications; } PGOutputData; -#endif /* PGOUTPUT_H */ +#endif /* PGOUTPUT_H */ diff --git a/src/include/replication/reorderbuffer.h b/src/include/replication/reorderbuffer.h index 17e47b385b..86effe106b 100644 --- a/src/include/replication/reorderbuffer.h +++ b/src/include/replication/reorderbuffer.h @@ -213,6 +213,15 @@ typedef struct ReorderBufferTXN uint64 nentries_mem; /* + * Has this transaction been spilled to disk? It's not always possible to + * deduce that fact by comparing nentries with nentries_mem, because e.g. + * subtransactions of a large transaction might get serialized together + * with the parent - if they're restored to memory they'd have + * nentries_mem == nentries. + */ + bool serialized; + + /* * List of ReorderBufferChange structs, including new Snapshots and new * CommandIds */ @@ -267,30 +276,30 @@ typedef struct ReorderBuffer ReorderBuffer; /* change callback signature */ typedef void (*ReorderBufferApplyChangeCB) ( - ReorderBuffer *rb, - ReorderBufferTXN *txn, - Relation relation, - ReorderBufferChange *change); + ReorderBuffer *rb, + ReorderBufferTXN *txn, + Relation relation, + ReorderBufferChange *change); /* begin callback signature */ typedef void (*ReorderBufferBeginCB) ( - ReorderBuffer *rb, - ReorderBufferTXN *txn); + ReorderBuffer *rb, + ReorderBufferTXN *txn); /* commit callback signature */ typedef void (*ReorderBufferCommitCB) ( - ReorderBuffer *rb, - ReorderBufferTXN *txn, - XLogRecPtr commit_lsn); + ReorderBuffer *rb, + ReorderBufferTXN *txn, + XLogRecPtr commit_lsn); /* message callback signature */ typedef void (*ReorderBufferMessageCB) ( - ReorderBuffer *rb, - ReorderBufferTXN *txn, - XLogRecPtr message_lsn, - bool transactional, - const char *prefix, Size sz, - const char *message); + ReorderBuffer *rb, + ReorderBufferTXN *txn, + XLogRecPtr message_lsn, + bool transactional, + const char *prefix, Size sz, + const char *message); struct ReorderBuffer { @@ -372,7 +381,7 @@ void ReorderBufferQueueMessage(ReorderBuffer *, TransactionId, Snapshot snapshot Size message_size, const char *message); void ReorderBufferCommit(ReorderBuffer *, TransactionId, XLogRecPtr commit_lsn, XLogRecPtr end_lsn, - TimestampTz commit_time, RepOriginId origin_id, XLogRecPtr origin_lsn); + TimestampTz commit_time, RepOriginId origin_id, XLogRecPtr origin_lsn); void ReorderBufferAssignChild(ReorderBuffer *, TransactionId, TransactionId, XLogRecPtr commit_lsn); void ReorderBufferCommitChild(ReorderBuffer *, TransactionId, TransactionId, XLogRecPtr commit_lsn, XLogRecPtr end_lsn); @@ -386,7 +395,7 @@ void ReorderBufferAddNewCommandId(ReorderBuffer *, TransactionId, XLogRecPtr lsn CommandId cid); void ReorderBufferAddNewTupleCids(ReorderBuffer *, TransactionId, XLogRecPtr lsn, RelFileNode node, ItemPointerData pt, - CommandId cmin, CommandId cmax, CommandId combocid); + CommandId cmin, CommandId cmax, CommandId combocid); void ReorderBufferAddInvalidations(ReorderBuffer *, TransactionId, XLogRecPtr lsn, Size nmsgs, SharedInvalidationMessage *msgs); void ReorderBufferImmediateInvalidation(ReorderBuffer *, uint32 ninvalidations, diff --git a/src/include/replication/slot.h b/src/include/replication/slot.h index 9a2dbd7b61..a283f4e2b8 100644 --- a/src/include/replication/slot.h +++ b/src/include/replication/slot.h @@ -184,4 +184,4 @@ extern void CheckPointReplicationSlots(void); extern void CheckSlotRequirements(void); -#endif /* SLOT_H */ +#endif /* SLOT_H */ diff --git a/src/include/replication/snapbuild.h b/src/include/replication/snapbuild.h index dc676a0ce2..7653717f83 100644 --- a/src/include/replication/snapbuild.h +++ b/src/include/replication/snapbuild.h @@ -87,4 +87,4 @@ extern void SnapBuildProcessRunningXacts(SnapBuild *builder, XLogRecPtr lsn, struct xl_running_xacts *running); extern void SnapBuildSerializationPoint(SnapBuild *builder, XLogRecPtr lsn); -#endif /* SNAPBUILD_H */ +#endif /* SNAPBUILD_H */ diff --git a/src/include/replication/syncrep.h b/src/include/replication/syncrep.h index 1676ea0952..ceafe2cbea 100644 --- a/src/include/replication/syncrep.h +++ b/src/include/replication/syncrep.h @@ -94,4 +94,4 @@ extern void syncrep_yyerror(const char *str); extern void syncrep_scanner_init(const char *query_string); extern void syncrep_scanner_finish(void); -#endif /* _SYNCREP_H */ +#endif /* _SYNCREP_H */ diff --git a/src/include/replication/walreceiver.h b/src/include/replication/walreceiver.h index 31d090c99d..c8652dbd48 100644 --- a/src/include/replication/walreceiver.h +++ b/src/include/replication/walreceiver.h @@ -153,7 +153,7 @@ typedef struct struct { uint32 proto_version; /* Logical protocol version */ - List *publication_names; /* String list of publications */ + List *publication_names; /* String list of publications */ } logical; } proto; } WalRcvStreamOptions; @@ -192,33 +192,33 @@ typedef struct WalRcvExecResult /* libpqwalreceiver hooks */ typedef WalReceiverConn *(*walrcv_connect_fn) (const char *conninfo, bool logical, - const char *appname, - char **err); + const char *appname, + char **err); typedef void (*walrcv_check_conninfo_fn) (const char *conninfo); typedef char *(*walrcv_get_conninfo_fn) (WalReceiverConn *conn); typedef char *(*walrcv_identify_system_fn) (WalReceiverConn *conn, - TimeLineID *primary_tli, - int *server_version); + TimeLineID *primary_tli, + int *server_version); typedef void (*walrcv_readtimelinehistoryfile_fn) (WalReceiverConn *conn, - TimeLineID tli, - char **filename, - char **content, int *size); + TimeLineID tli, + char **filename, + char **content, int *size); typedef bool (*walrcv_startstreaming_fn) (WalReceiverConn *conn, - const WalRcvStreamOptions *options); + const WalRcvStreamOptions *options); typedef void (*walrcv_endstreaming_fn) (WalReceiverConn *conn, - TimeLineID *next_tli); + TimeLineID *next_tli); typedef int (*walrcv_receive_fn) (WalReceiverConn *conn, char **buffer, - pgsocket *wait_fd); + pgsocket *wait_fd); typedef void (*walrcv_send_fn) (WalReceiverConn *conn, const char *buffer, - int nbytes); + int nbytes); typedef char *(*walrcv_create_slot_fn) (WalReceiverConn *conn, const char *slotname, bool temporary, - CRSSnapshotAction snapshot_action, - XLogRecPtr *lsn); + CRSSnapshotAction snapshot_action, + XLogRecPtr *lsn); typedef WalRcvExecResult *(*walrcv_exec_fn) (WalReceiverConn *conn, - const char *query, - const int nRetTypes, - const Oid *retTypes); + const char *query, + const int nRetTypes, + const Oid *retTypes); typedef void (*walrcv_disconnect_fn) (WalReceiverConn *conn); typedef struct WalReceiverFunctionsType @@ -298,4 +298,4 @@ extern int GetReplicationApplyDelay(void); extern int GetReplicationTransferLatency(void); extern void WalRcvForceReply(void); -#endif /* _WALRECEIVER_H */ +#endif /* _WALRECEIVER_H */ diff --git a/src/include/replication/walsender.h b/src/include/replication/walsender.h index c50e450ec2..1f20db827a 100644 --- a/src/include/replication/walsender.h +++ b/src/include/replication/walsender.h @@ -72,4 +72,4 @@ extern void WalSndRqstFileReload(void); } \ } while (0) -#endif /* _WALSENDER_H */ +#endif /* _WALSENDER_H */ diff --git a/src/include/replication/walsender_private.h b/src/include/replication/walsender_private.h index 36311e124c..0aa80d5c3e 100644 --- a/src/include/replication/walsender_private.h +++ b/src/include/replication/walsender_private.h @@ -114,4 +114,4 @@ extern void replication_scanner_finish(void); extern Node *replication_parse_result; -#endif /* _WALSENDER_PRIVATE_H */ +#endif /* _WALSENDER_PRIVATE_H */ diff --git a/src/include/replication/worker_internal.h b/src/include/replication/worker_internal.h index 2bfff5c120..494a3a3d08 100644 --- a/src/include/replication/worker_internal.h +++ b/src/include/replication/worker_internal.h @@ -90,4 +90,4 @@ am_tablesync_worker(void) return OidIsValid(MyLogicalRepWorker->relid); } -#endif /* WORKER_INTERNAL_H */ +#endif /* WORKER_INTERNAL_H */ diff --git a/src/include/rewrite/prs2lock.h b/src/include/rewrite/prs2lock.h index 36dca02a7e..419d140bd5 100644 --- a/src/include/rewrite/prs2lock.h +++ b/src/include/rewrite/prs2lock.h @@ -43,4 +43,4 @@ typedef struct RuleLock RewriteRule **rules; } RuleLock; -#endif /* REWRITE_H */ +#endif /* REWRITE_H */ diff --git a/src/include/rewrite/rewriteDefine.h b/src/include/rewrite/rewriteDefine.h index 5495700970..2e25288bb4 100644 --- a/src/include/rewrite/rewriteDefine.h +++ b/src/include/rewrite/rewriteDefine.h @@ -41,4 +41,4 @@ extern void setRuleCheckAsUser(Node *node, Oid userid); extern void EnableDisableRule(Relation rel, const char *rulename, char fires_when); -#endif /* REWRITEDEFINE_H */ +#endif /* REWRITEDEFINE_H */ diff --git a/src/include/rewrite/rewriteHandler.h b/src/include/rewrite/rewriteHandler.h index 4504968437..bbac12707d 100644 --- a/src/include/rewrite/rewriteHandler.h +++ b/src/include/rewrite/rewriteHandler.h @@ -34,4 +34,4 @@ extern int relation_is_updatable(Oid reloid, extern List *QueryRewriteCTAS(Query *parsetree); #endif -#endif /* REWRITEHANDLER_H */ +#endif /* REWRITEHANDLER_H */ diff --git a/src/include/rewrite/rewriteManip.h b/src/include/rewrite/rewriteManip.h index 3910bceb2a..282ff9967f 100644 --- a/src/include/rewrite/rewriteManip.h +++ b/src/include/rewrite/rewriteManip.h @@ -20,7 +20,7 @@ typedef struct replace_rte_variables_context replace_rte_variables_context; typedef Node *(*replace_rte_variables_callback) (Var *var, - replace_rte_variables_context *context); + replace_rte_variables_context *context); struct replace_rte_variables_context { @@ -28,7 +28,7 @@ struct replace_rte_variables_context void *callback_arg; /* context data for callback function */ int target_varno; /* RTE index to search for */ int sublevels_up; /* (current) nesting depth */ - bool inserted_sublink; /* have we inserted a SubLink? */ + bool inserted_sublink; /* have we inserted a SubLink? */ }; typedef enum ReplaceVarsNoMatchOption @@ -82,4 +82,4 @@ extern Node *ReplaceVarsFromTargetList(Node *node, int nomatch_varno, bool *outer_hasSubLinks); -#endif /* REWRITEMANIP_H */ +#endif /* REWRITEMANIP_H */ diff --git a/src/include/rewrite/rewriteRemove.h b/src/include/rewrite/rewriteRemove.h index 28c9be72db..d7d53b0137 100644 --- a/src/include/rewrite/rewriteRemove.h +++ b/src/include/rewrite/rewriteRemove.h @@ -18,4 +18,4 @@ extern void RemoveRewriteRuleById(Oid ruleOid); -#endif /* REWRITEREMOVE_H */ +#endif /* REWRITEREMOVE_H */ diff --git a/src/include/rewrite/rewriteSupport.h b/src/include/rewrite/rewriteSupport.h index d287bbda78..60800aae25 100644 --- a/src/include/rewrite/rewriteSupport.h +++ b/src/include/rewrite/rewriteSupport.h @@ -23,4 +23,4 @@ extern void SetRelationRuleStatus(Oid relationId, bool relHasRules); extern Oid get_rewrite_oid(Oid relid, const char *rulename, bool missing_ok); -#endif /* REWRITESUPPORT_H */ +#endif /* REWRITESUPPORT_H */ diff --git a/src/include/rewrite/rowsecurity.h b/src/include/rewrite/rowsecurity.h index 0e739fd334..0dbc1a4bee 100644 --- a/src/include/rewrite/rowsecurity.h +++ b/src/include/rewrite/rowsecurity.h @@ -35,7 +35,7 @@ typedef struct RowSecurityDesc } RowSecurityDesc; typedef List *(*row_security_policy_hook_type) (CmdType cmdtype, - Relation relation); + Relation relation); extern PGDLLIMPORT row_security_policy_hook_type row_security_policy_hook_permissive; @@ -46,4 +46,4 @@ extern void get_row_security_policies(Query *root, List **securityQuals, List **withCheckOptions, bool *hasRowSecurity, bool *hasSubLinks); -#endif /* ROWSECURITY_H */ +#endif /* ROWSECURITY_H */ diff --git a/src/include/rusagestub.h b/src/include/rusagestub.h index 0e366cab10..f54f66e6f3 100644 --- a/src/include/rusagestub.h +++ b/src/include/rusagestub.h @@ -29,6 +29,6 @@ struct rusage struct timeval ru_stime; /* system time used */ }; -extern int getrusage(int who, struct rusage * rusage); +extern int getrusage(int who, struct rusage *rusage); -#endif /* RUSAGESTUB_H */ +#endif /* RUSAGESTUB_H */ diff --git a/src/include/snowball/header.h b/src/include/snowball/header.h index d8be02ee60..10acf4c53d 100644 --- a/src/include/snowball/header.h +++ b/src/include/snowball/header.h @@ -64,4 +64,4 @@ #endif #define free(a) pfree(a) -#endif /* SNOWBALL_HEADR_H */ +#endif /* SNOWBALL_HEADR_H */ diff --git a/src/include/statistics/extended_stats_internal.h b/src/include/statistics/extended_stats_internal.h index dc72e2f479..738ff3fadc 100644 --- a/src/include/statistics/extended_stats_internal.h +++ b/src/include/statistics/extended_stats_internal.h @@ -66,4 +66,4 @@ extern int multi_sort_compare_dim(int dim, const SortItem *a, extern int multi_sort_compare_dims(int start, int end, const SortItem *a, const SortItem *b, MultiSortSupport mss); -#endif /* EXTENDED_STATS_INTERNAL_H */ +#endif /* EXTENDED_STATS_INTERNAL_H */ diff --git a/src/include/statistics/statistics.h b/src/include/statistics/statistics.h index a3f0d90195..1d68c39df0 100644 --- a/src/include/statistics/statistics.h +++ b/src/include/statistics/statistics.h @@ -16,7 +16,7 @@ #include "commands/vacuum.h" #include "nodes/relation.h" -#define STATS_MAX_DIMENSIONS 8 /* max number of attributes */ +#define STATS_MAX_DIMENSIONS 8 /* max number of attributes */ /* Multivariate distinct coefficients */ #define STATS_NDISTINCT_MAGIC 0xA352BFA4 /* struct identifier */ @@ -28,6 +28,7 @@ typedef struct MVNDistinctItem double ndistinct; /* ndistinct value for this combination */ Bitmapset *attrs; /* attr numbers of items */ } MVNDistinctItem; + /* size of the struct, excluding attribute list */ #define SizeOfMVNDistinctItem \ (offsetof(MVNDistinctItem, ndistinct) + sizeof(double)) @@ -48,8 +49,8 @@ typedef struct MVNDistinct /* size of the struct excluding the items array */ #define SizeOfMVNDistinct (offsetof(MVNDistinct, nitems) + sizeof(uint32)) -#define STATS_DEPS_MAGIC 0xB4549A2C /* marks serialized bytea */ -#define STATS_DEPS_TYPE_BASIC 1 /* basic dependencies type */ +#define STATS_DEPS_MAGIC 0xB4549A2C /* marks serialized bytea */ +#define STATS_DEPS_TYPE_BASIC 1 /* basic dependencies type */ /* * Functional dependencies, tracking column-level relationships (values @@ -59,7 +60,7 @@ typedef struct MVDependency { double degree; /* degree of validity (0-1) */ AttrNumber nattributes; /* number of attributes */ - AttrNumber attributes[FLEXIBLE_ARRAY_MEMBER]; /* attribute numbers */ + AttrNumber attributes[FLEXIBLE_ARRAY_MEMBER]; /* attribute numbers */ } MVDependency; /* size of the struct excluding the deps array */ @@ -78,7 +79,7 @@ typedef struct MVDependencies #define SizeOfDependencies (offsetof(MVDependencies, ndeps) + sizeof(uint32)) extern MVNDistinct *statext_ndistinct_load(Oid mvoid); -extern MVDependencies *staext_dependencies_load(Oid mvoid); +extern MVDependencies *statext_dependencies_load(Oid mvoid); extern void BuildRelationExtStatistics(Relation onerel, double totalrows, int numrows, HeapTuple *rows, @@ -95,4 +96,4 @@ extern bool has_stats_of_kind(List *stats, char requiredkind); extern StatisticExtInfo *choose_best_statistics(List *stats, Bitmapset *attnums, char requiredkind); -#endif /* STATISTICS_H */ +#endif /* STATISTICS_H */ diff --git a/src/include/storage/backendid.h b/src/include/storage/backendid.h index 3445caeb93..5dea030510 100644 --- a/src/include/storage/backendid.h +++ b/src/include/storage/backendid.h @@ -23,7 +23,7 @@ typedef int BackendId; /* unique currently active backend identifier */ #define InvalidBackendId (-1) -extern PGDLLIMPORT BackendId MyBackendId; /* backend id of this backend */ +extern PGDLLIMPORT BackendId MyBackendId; /* backend id of this backend */ #ifdef XCP /* @@ -51,4 +51,4 @@ extern PGDLLIMPORT BackendId ParallelMasterBackendId; #define BackendIdForTempRelations() \ (ParallelMasterBackendId == InvalidBackendId ? MyBackendId : ParallelMasterBackendId) -#endif /* BACKENDID_H */ +#endif /* BACKENDID_H */ diff --git a/src/include/storage/block.h b/src/include/storage/block.h index ec847bbb7a..33840798a8 100644 --- a/src/include/storage/block.h +++ b/src/include/storage/block.h @@ -118,4 +118,4 @@ typedef BlockIdData *BlockId; /* block identifier */ (BlockNumber) (((blockId)->bi_hi << 16) | ((uint16) (blockId)->bi_lo)) \ ) -#endif /* BLOCK_H */ +#endif /* BLOCK_H */ diff --git a/src/include/storage/buf.h b/src/include/storage/buf.h index ac33b83b4b..054f482bd7 100644 --- a/src/include/storage/buf.h +++ b/src/include/storage/buf.h @@ -43,4 +43,4 @@ typedef int Buffer; */ typedef struct BufferAccessStrategyData *BufferAccessStrategy; -#endif /* BUF_H */ +#endif /* BUF_H */ diff --git a/src/include/storage/buf_internals.h b/src/include/storage/buf_internals.h index ff99f6b5e2..b768b6fc96 100644 --- a/src/include/storage/buf_internals.h +++ b/src/include/storage/buf_internals.h @@ -55,17 +55,17 @@ * Note: TAG_VALID essentially means that there is a buffer hashtable * entry associated with the buffer's tag. */ -#define BM_LOCKED (1U << 22) /* buffer header is locked */ -#define BM_DIRTY (1U << 23) /* data needs writing */ -#define BM_VALID (1U << 24) /* data is valid */ -#define BM_TAG_VALID (1U << 25) /* tag is assigned */ -#define BM_IO_IN_PROGRESS (1U << 26) /* read or write in progress */ -#define BM_IO_ERROR (1U << 27) /* previous I/O failed */ -#define BM_JUST_DIRTIED (1U << 28) /* dirtied since write started */ -#define BM_PIN_COUNT_WAITER (1U << 29) /* have waiter for sole pin */ -#define BM_CHECKPOINT_NEEDED (1U << 30) /* must write for checkpoint */ -#define BM_PERMANENT (1U << 31) /* permanent buffer (not - * unlogged, or init fork) */ +#define BM_LOCKED (1U << 22) /* buffer header is locked */ +#define BM_DIRTY (1U << 23) /* data needs writing */ +#define BM_VALID (1U << 24) /* data is valid */ +#define BM_TAG_VALID (1U << 25) /* tag is assigned */ +#define BM_IO_IN_PROGRESS (1U << 26) /* read or write in progress */ +#define BM_IO_ERROR (1U << 27) /* previous I/O failed */ +#define BM_JUST_DIRTIED (1U << 28) /* dirtied since write started */ +#define BM_PIN_COUNT_WAITER (1U << 29) /* have waiter for sole pin */ +#define BM_CHECKPOINT_NEEDED (1U << 30) /* must write for checkpoint */ +#define BM_PERMANENT (1U << 31) /* permanent buffer (not unlogged, + * or init fork) */ /* * The maximum allowed value of usage_count represents a tradeoff between * accuracy and speed of the clock-sweep buffer management algorithm. A @@ -183,7 +183,7 @@ typedef struct BufferDesc /* state of the tag, containing flags, refcount and usagecount */ pg_atomic_uint32 state; - int wait_backend_pid; /* backend PID of pin-count waiter */ + int wait_backend_pid; /* backend PID of pin-count waiter */ int freeNext; /* link in freelist chain */ LWLock content_lock; /* to lock access to buffer contents */ @@ -337,4 +337,4 @@ extern void DropRelFileNodeLocalBuffers(RelFileNode rnode, ForkNumber forkNum, extern void DropRelFileNodeAllLocalBuffers(RelFileNode rnode); extern void AtEOXact_LocalBuffers(bool isCommit); -#endif /* BUFMGR_INTERNALS_H */ +#endif /* BUFMGR_INTERNALS_H */ diff --git a/src/include/storage/buffile.h b/src/include/storage/buffile.h index fe00bf0c31..fafcb3f089 100644 --- a/src/include/storage/buffile.h +++ b/src/include/storage/buffile.h @@ -42,4 +42,4 @@ extern int BufFileSeek(BufFile *file, int fileno, off_t offset, int whence); extern void BufFileTell(BufFile *file, int *fileno, off_t *offset); extern int BufFileSeekBlock(BufFile *file, long blknum); -#endif /* BUFFILE_H */ +#endif /* BUFFILE_H */ diff --git a/src/include/storage/bufmgr.h b/src/include/storage/bufmgr.h index 07a32d6dfc..98b63fc5ba 100644 --- a/src/include/storage/bufmgr.h +++ b/src/include/storage/bufmgr.h @@ -79,7 +79,7 @@ extern PGDLLIMPORT int32 *LocalRefCount; #define MAX_IO_CONCURRENCY 1000 /* special block number for ReadBuffer() */ -#define P_NEW InvalidBlockNumber /* grow the file to get a new page */ +#define P_NEW InvalidBlockNumber /* grow the file to get a new page */ /* * Buffer content lock modes (mode argument for LockBuffer()) @@ -275,6 +275,6 @@ TestForOldSnapshot(Snapshot snapshot, Relation relation, Page page) TestForOldSnapshot_impl(snapshot, relation); } -#endif /* FRONTEND */ +#endif /* FRONTEND */ -#endif /* BUFMGR_H */ +#endif /* BUFMGR_H */ diff --git a/src/include/storage/bufpage.h b/src/include/storage/bufpage.h index e956dc3386..50c72a3c8d 100644 --- a/src/include/storage/bufpage.h +++ b/src/include/storage/bufpage.h @@ -173,13 +173,12 @@ typedef PageHeaderData *PageHeader; * page for its new tuple version; this suggests that a prune is needed. * Again, this is just a hint. */ -#define PD_HAS_FREE_LINES 0x0001 /* are there any unused line pointers? */ -#define PD_PAGE_FULL 0x0002 /* not enough free space for new - * tuple? */ -#define PD_ALL_VISIBLE 0x0004 /* all tuples on page are visible to - * everyone */ +#define PD_HAS_FREE_LINES 0x0001 /* are there any unused line pointers? */ +#define PD_PAGE_FULL 0x0002 /* not enough free space for new tuple? */ +#define PD_ALL_VISIBLE 0x0004 /* all tuples on page are visible to + * everyone */ -#define PD_VALID_FLAG_BITS 0x0007 /* OR of all valid pd_flags bits */ +#define PD_VALID_FLAG_BITS 0x0007 /* OR of all valid pd_flags bits */ /* * Page layout version number 0 is for pre-7.3 Postgres releases. @@ -436,4 +435,4 @@ extern bool PageIndexTupleOverwrite(Page page, OffsetNumber offnum, extern char *PageSetChecksumCopy(Page page, BlockNumber blkno); extern void PageSetChecksumInplace(Page page, BlockNumber blkno); -#endif /* BUFPAGE_H */ +#endif /* BUFPAGE_H */ diff --git a/src/include/storage/checksum.h b/src/include/storage/checksum.h index 682043f8e7..b85f714712 100644 --- a/src/include/storage/checksum.h +++ b/src/include/storage/checksum.h @@ -21,4 +21,4 @@ */ extern uint16 pg_checksum_page(char *page, BlockNumber blkno); -#endif /* CHECKSUM_H */ +#endif /* CHECKSUM_H */ diff --git a/src/include/storage/condition_variable.h b/src/include/storage/condition_variable.h index 89f5d5804b..f77c0b22ad 100644 --- a/src/include/storage/condition_variable.h +++ b/src/include/storage/condition_variable.h @@ -56,4 +56,4 @@ extern void ConditionVariablePrepareToSleep(ConditionVariable *); extern bool ConditionVariableSignal(ConditionVariable *); extern int ConditionVariableBroadcast(ConditionVariable *); -#endif /* CONDITION_VARIABLE_H */ +#endif /* CONDITION_VARIABLE_H */ diff --git a/src/include/storage/copydir.h b/src/include/storage/copydir.h index c3722b4033..f88a044509 100644 --- a/src/include/storage/copydir.h +++ b/src/include/storage/copydir.h @@ -16,4 +16,4 @@ extern void copydir(char *fromdir, char *todir, bool recurse); extern void copy_file(char *fromfile, char *tofile); -#endif /* COPYDIR_H */ +#endif /* COPYDIR_H */ diff --git a/src/include/storage/dsm.h b/src/include/storage/dsm.h index 7d1250c1e0..31b1f4da9c 100644 --- a/src/include/storage/dsm.h +++ b/src/include/storage/dsm.h @@ -60,4 +60,4 @@ extern void cancel_on_dsm_detach(dsm_segment *seg, on_dsm_detach_callback function, Datum arg); extern void reset_on_dsm_detach(void); -#endif /* DSM_H */ +#endif /* DSM_H */ diff --git a/src/include/storage/dsm_impl.h b/src/include/storage/dsm_impl.h index 51c217899d..c2060431ba 100644 --- a/src/include/storage/dsm_impl.h +++ b/src/include/storage/dsm_impl.h @@ -77,4 +77,4 @@ extern void dsm_impl_pin_segment(dsm_handle handle, void *impl_private, void **impl_private_pm_handle); extern void dsm_impl_unpin_segment(dsm_handle handle, void **impl_private); -#endif /* DSM_IMPL_H */ +#endif /* DSM_IMPL_H */ diff --git a/src/include/storage/fd.h b/src/include/storage/fd.h index 05680499e4..faef39e78d 100644 --- a/src/include/storage/fd.h +++ b/src/include/storage/fd.h @@ -127,4 +127,4 @@ extern void SyncDataDirectory(void); #define PG_TEMP_FILES_DIR "pgsql_tmp" #define PG_TEMP_FILE_PREFIX "pgsql_tmp" -#endif /* FD_H */ +#endif /* FD_H */ diff --git a/src/include/storage/freespace.h b/src/include/storage/freespace.h index 9a5c9f4be4..d110f006af 100644 --- a/src/include/storage/freespace.h +++ b/src/include/storage/freespace.h @@ -37,4 +37,4 @@ extern void UpdateFreeSpaceMap(Relation rel, BlockNumber endBlkNum, Size freespace); -#endif /* FREESPACE_H_ */ +#endif /* FREESPACE_H_ */ diff --git a/src/include/storage/fsm_internals.h b/src/include/storage/fsm_internals.h index 4eb3fc12b1..722e649123 100644 --- a/src/include/storage/fsm_internals.h +++ b/src/include/storage/fsm_internals.h @@ -69,4 +69,4 @@ extern bool fsm_set_avail(Page page, int slot, uint8 value); extern bool fsm_truncate_avail(Page page, int nslots); extern bool fsm_rebuild_page(Page page); -#endif /* FSM_INTERNALS_H */ +#endif /* FSM_INTERNALS_H */ diff --git a/src/include/storage/indexfsm.h b/src/include/storage/indexfsm.h index b256ee6aef..f8045f0df8 100644 --- a/src/include/storage/indexfsm.h +++ b/src/include/storage/indexfsm.h @@ -23,4 +23,4 @@ extern void RecordUsedIndexPage(Relation rel, BlockNumber page); extern void IndexFreeSpaceMapVacuum(Relation rel); -#endif /* INDEXFSM_H_ */ +#endif /* INDEXFSM_H_ */ diff --git a/src/include/storage/ipc.h b/src/include/storage/ipc.h index 8d5a6b2698..bde635f502 100644 --- a/src/include/storage/ipc.h +++ b/src/include/storage/ipc.h @@ -77,4 +77,4 @@ extern PGDLLIMPORT shmem_startup_hook_type shmem_startup_hook; extern void CreateSharedMemoryAndSemaphores(bool makePrivate, int port); -#endif /* IPC_H */ +#endif /* IPC_H */ diff --git a/src/include/storage/item.h b/src/include/storage/item.h index d19e19e01b..72426a2d48 100644 --- a/src/include/storage/item.h +++ b/src/include/storage/item.h @@ -16,4 +16,4 @@ typedef Pointer Item; -#endif /* ITEM_H */ +#endif /* ITEM_H */ diff --git a/src/include/storage/itemid.h b/src/include/storage/itemid.h index af77852cc0..2ec86b57fc 100644 --- a/src/include/storage/itemid.h +++ b/src/include/storage/itemid.h @@ -180,4 +180,4 @@ typedef uint16 ItemLength; (itemId)->lp_flags = LP_DEAD \ ) -#endif /* ITEMID_H */ +#endif /* ITEMID_H */ diff --git a/src/include/storage/itemptr.h b/src/include/storage/itemptr.h index c21d2adfcb..8f8e22444a 100644 --- a/src/include/storage/itemptr.h +++ b/src/include/storage/itemptr.h @@ -38,6 +38,7 @@ typedef struct ItemPointerData BlockIdData ip_blkid; OffsetNumber ip_posid; } + /* If compiler understands packed and aligned pragmas, use those */ #if defined(pg_attribute_packed) && defined(pg_attribute_aligned) pg_attribute_packed() @@ -161,4 +162,4 @@ typedef ItemPointerData *ItemPointer; extern bool ItemPointerEquals(ItemPointer pointer1, ItemPointer pointer2); extern int32 ItemPointerCompare(ItemPointer arg1, ItemPointer arg2); -#endif /* ITEMPTR_H */ +#endif /* ITEMPTR_H */ diff --git a/src/include/storage/large_object.h b/src/include/storage/large_object.h index fc55019b98..796a8fdeea 100644 --- a/src/include/storage/large_object.h +++ b/src/include/storage/large_object.h @@ -94,4 +94,4 @@ extern int inv_read(LargeObjectDesc *obj_desc, char *buf, int nbytes); extern int inv_write(LargeObjectDesc *obj_desc, const char *buf, int nbytes); extern void inv_truncate(LargeObjectDesc *obj_desc, int64 len); -#endif /* LARGE_OBJECT_H */ +#endif /* LARGE_OBJECT_H */ diff --git a/src/include/storage/latch.h b/src/include/storage/latch.h index 3158d7bec6..73abfafec5 100644 --- a/src/include/storage/latch.h +++ b/src/include/storage/latch.h @@ -176,4 +176,4 @@ extern void latch_sigusr1_handler(void); #define latch_sigusr1_handler() ((void) 0) #endif -#endif /* LATCH_H */ +#endif /* LATCH_H */ diff --git a/src/include/storage/lmgr.h b/src/include/storage/lmgr.h index 2a1244c836..0b923227a2 100644 --- a/src/include/storage/lmgr.h +++ b/src/include/storage/lmgr.h @@ -106,4 +106,4 @@ extern void DescribeLockTag(StringInfo buf, const LOCKTAG *tag); extern const char *GetLockNameFromTagType(uint16 locktag_type); -#endif /* LMGR_H */ +#endif /* LMGR_H */ diff --git a/src/include/storage/lock.h b/src/include/storage/lock.h index 3abeb59fc7..2f5874644b 100644 --- a/src/include/storage/lock.h +++ b/src/include/storage/lock.h @@ -42,7 +42,7 @@ extern bool Trace_locks; extern bool Trace_userlocks; extern int Trace_lock_table; extern bool Debug_deadlocks; -#endif /* LOCK_DEBUG */ +#endif /* LOCK_DEBUG */ /* @@ -63,8 +63,7 @@ extern bool Debug_deadlocks; typedef struct { BackendId backendId; /* determined at backend startup */ - LocalTransactionId localTransactionId; /* backend-local transaction - * id */ + LocalTransactionId localTransactionId; /* backend-local transaction id */ } VirtualTransactionId; #define InvalidLocalTransactionId 0 @@ -113,7 +112,7 @@ typedef struct LockMethodData { int numLockModes; const LOCKMASK *conflictTab; - const char *const * lockModeNames; + const char *const *lockModeNames; const bool *trace_flag; } LockMethodData; @@ -292,7 +291,7 @@ typedef struct LOCK LOCKMASK waitMask; /* bitmask for lock types awaited */ SHM_QUEUE procLocks; /* list of PROCLOCK objects assoc. with lock */ PROC_QUEUE waitProcs; /* list of PGPROC objects waiting on lock */ - int requested[MAX_LOCKMODES]; /* counts of requested locks */ + int requested[MAX_LOCKMODES]; /* counts of requested locks */ int nRequested; /* total of requested[] array */ int granted[MAX_LOCKMODES]; /* counts of granted locks */ int nGranted; /* total of granted[] array */ @@ -587,4 +586,4 @@ extern void VirtualXactLockTableInsert(VirtualTransactionId vxid); extern void VirtualXactLockTableCleanup(void); extern bool VirtualXactLock(VirtualTransactionId vxid, bool wait); -#endif /* LOCK_H */ +#endif /* LOCK_H */ diff --git a/src/include/storage/lockdefs.h b/src/include/storage/lockdefs.h index bfeb8779f7..fe9f7cb310 100644 --- a/src/include/storage/lockdefs.h +++ b/src/include/storage/lockdefs.h @@ -33,18 +33,17 @@ typedef int LOCKMODE; /* NoLock is not a lock mode, but a flag value meaning "don't get a lock" */ #define NoLock 0 -#define AccessShareLock 1 /* SELECT */ -#define RowShareLock 2 /* SELECT FOR UPDATE/FOR SHARE */ -#define RowExclusiveLock 3 /* INSERT, UPDATE, DELETE */ -#define ShareUpdateExclusiveLock 4 /* VACUUM (non-FULL),ANALYZE, CREATE - * INDEX CONCURRENTLY */ -#define ShareLock 5 /* CREATE INDEX (WITHOUT CONCURRENTLY) */ -#define ShareRowExclusiveLock 6 /* like EXCLUSIVE MODE, but allows ROW - * SHARE */ -#define ExclusiveLock 7 /* blocks ROW SHARE/SELECT...FOR - * UPDATE */ -#define AccessExclusiveLock 8 /* ALTER TABLE, DROP TABLE, VACUUM - * FULL, and unqualified LOCK TABLE */ +#define AccessShareLock 1 /* SELECT */ +#define RowShareLock 2 /* SELECT FOR UPDATE/FOR SHARE */ +#define RowExclusiveLock 3 /* INSERT, UPDATE, DELETE */ +#define ShareUpdateExclusiveLock 4 /* VACUUM (non-FULL),ANALYZE, CREATE INDEX + * CONCURRENTLY */ +#define ShareLock 5 /* CREATE INDEX (WITHOUT CONCURRENTLY) */ +#define ShareRowExclusiveLock 6 /* like EXCLUSIVE MODE, but allows ROW + * SHARE */ +#define ExclusiveLock 7 /* blocks ROW SHARE/SELECT...FOR UPDATE */ +#define AccessExclusiveLock 8 /* ALTER TABLE, DROP TABLE, VACUUM FULL, + * and unqualified LOCK TABLE */ typedef struct xl_standby_lock { @@ -53,4 +52,4 @@ typedef struct xl_standby_lock Oid relOid; } xl_standby_lock; -#endif /* LOCKDEF_H_ */ +#endif /* LOCKDEF_H_ */ diff --git a/src/include/storage/lwlock.h b/src/include/storage/lwlock.h index c22daef179..7e0859d0d5 100644 --- a/src/include/storage/lwlock.h +++ b/src/include/storage/lwlock.h @@ -216,7 +216,7 @@ typedef enum BuiltinTrancheIds LWTRANCHE_PARALLEL_QUERY_DSA, LWTRANCHE_TBM, LWTRANCHE_FIRST_USER_DEFINED -} BuiltinTrancheIds; +} BuiltinTrancheIds; /* * Prior to PostgreSQL 9.4, we used an enum type called LWLockId to refer @@ -225,4 +225,4 @@ typedef enum BuiltinTrancheIds */ typedef LWLock *LWLockId; -#endif /* LWLOCK_H */ +#endif /* LWLOCK_H */ diff --git a/src/include/storage/off.h b/src/include/storage/off.h index fe8638fe15..7228808b94 100644 --- a/src/include/storage/off.h +++ b/src/include/storage/off.h @@ -26,7 +26,7 @@ typedef uint16 OffsetNumber; #define InvalidOffsetNumber ((OffsetNumber) 0) #define FirstOffsetNumber ((OffsetNumber) 1) #define MaxOffsetNumber ((OffsetNumber) (BLCKSZ / sizeof(ItemIdData))) -#define OffsetNumberMask (0xffff) /* valid uint16 bits */ +#define OffsetNumberMask (0xffff) /* valid uint16 bits */ /* ---------------- * support macros @@ -55,4 +55,4 @@ typedef uint16 OffsetNumber; #define OffsetNumberPrev(offsetNumber) \ ((OffsetNumber) (-1 + (offsetNumber))) -#endif /* OFF_H */ +#endif /* OFF_H */ diff --git a/src/include/storage/pg_sema.h b/src/include/storage/pg_sema.h index b819f41d19..65db86f578 100644 --- a/src/include/storage/pg_sema.h +++ b/src/include/storage/pg_sema.h @@ -58,4 +58,4 @@ extern void PGSemaphoreUnlock(PGSemaphore sema); /* Lock a semaphore only if able to do so without blocking */ extern bool PGSemaphoreTryLock(PGSemaphore sema); -#endif /* PG_SEMA_H */ +#endif /* PG_SEMA_H */ diff --git a/src/include/storage/pg_shmem.h b/src/include/storage/pg_shmem.h index a329c81899..e3ee096229 100644 --- a/src/include/storage/pg_shmem.h +++ b/src/include/storage/pg_shmem.h @@ -50,7 +50,7 @@ typedef enum HUGE_PAGES_OFF, HUGE_PAGES_ON, HUGE_PAGES_TRY -} HugePagesType; +} HugePagesType; #ifndef WIN32 extern unsigned long UsedShmemSegID; @@ -69,4 +69,4 @@ extern PGShmemHeader *PGSharedMemoryCreate(Size size, bool makePrivate, extern bool PGSharedMemoryIsInUse(unsigned long id1, unsigned long id2); extern void PGSharedMemoryDetach(void); -#endif /* PG_SHMEM_H */ +#endif /* PG_SHMEM_H */ diff --git a/src/include/storage/pmsignal.h b/src/include/storage/pmsignal.h index 90ddfa3b31..4b954d7614 100644 --- a/src/include/storage/pmsignal.h +++ b/src/include/storage/pmsignal.h @@ -27,10 +27,10 @@ typedef enum PMSIGNAL_WAKEN_ARCHIVER, /* send a NOTIFY signal to xlog archiver */ PMSIGNAL_ROTATE_LOGFILE, /* send SIGUSR1 to syslogger to rotate logfile */ PMSIGNAL_START_AUTOVAC_LAUNCHER, /* start an autovacuum launcher */ - PMSIGNAL_START_AUTOVAC_WORKER, /* start an autovacuum worker */ + PMSIGNAL_START_AUTOVAC_WORKER, /* start an autovacuum worker */ PMSIGNAL_BACKGROUND_WORKER_CHANGE, /* background worker state change */ PMSIGNAL_START_WALRECEIVER, /* start a walreceiver */ - PMSIGNAL_ADVANCE_STATE_MACHINE, /* advance postmaster's state machine */ + PMSIGNAL_ADVANCE_STATE_MACHINE, /* advance postmaster's state machine */ NUM_PMSIGNALS /* Must be last value of enum! */ } PMSignalReason; @@ -53,4 +53,4 @@ extern void MarkPostmasterChildInactive(void); extern void MarkPostmasterChildWalSender(void); extern bool PostmasterIsAlive(void); -#endif /* PMSIGNAL_H */ +#endif /* PMSIGNAL_H */ diff --git a/src/include/storage/predicate.h b/src/include/storage/predicate.h index 941ba7119e..06bcbf2471 100644 --- a/src/include/storage/predicate.h +++ b/src/include/storage/predicate.h @@ -74,4 +74,4 @@ extern void PredicateLockTwoPhaseFinish(TransactionId xid, bool isCommit); extern void predicatelock_twophase_recover(TransactionId xid, uint16 info, void *recdata, uint32 len); -#endif /* PREDICATE_H */ +#endif /* PREDICATE_H */ diff --git a/src/include/storage/predicate_internals.h b/src/include/storage/predicate_internals.h index 3cb0ab9bb0..89874a5c3b 100644 --- a/src/include/storage/predicate_internals.h +++ b/src/include/storage/predicate_internals.h @@ -78,10 +78,10 @@ typedef struct SERIALIZABLEXACT /* these values are not both interesting at the same time */ union { - SerCommitSeqNo earliestOutConflictCommit; /* when committed with - * conflict out */ - SerCommitSeqNo lastCommitBeforeSnapshot; /* when not committed or - * no conflict out */ + SerCommitSeqNo earliestOutConflictCommit; /* when committed with + * conflict out */ + SerCommitSeqNo lastCommitBeforeSnapshot; /* when not committed or + * no conflict out */ } SeqNo; SHM_QUEUE outConflicts; /* list of write transactions whose data we * couldn't read. */ @@ -99,18 +99,18 @@ typedef struct SERIALIZABLEXACT TransactionId topXid; /* top level xid for the transaction, if one * exists; else invalid */ - TransactionId finishedBefore; /* invalid means still running; else - * the struct expires when no - * serializable xids are before this. */ + TransactionId finishedBefore; /* invalid means still running; else the + * struct expires when no serializable + * xids are before this. */ TransactionId xmin; /* the transaction's snapshot xmin */ uint32 flags; /* OR'd combination of values defined below */ int pid; /* pid of associated process */ } SERIALIZABLEXACT; -#define SXACT_FLAG_COMMITTED 0x00000001 /* already committed */ -#define SXACT_FLAG_PREPARED 0x00000002 /* about to commit */ -#define SXACT_FLAG_ROLLED_BACK 0x00000004 /* already rolled back */ -#define SXACT_FLAG_DOOMED 0x00000008 /* will roll back */ +#define SXACT_FLAG_COMMITTED 0x00000001 /* already committed */ +#define SXACT_FLAG_PREPARED 0x00000002 /* about to commit */ +#define SXACT_FLAG_ROLLED_BACK 0x00000004 /* already rolled back */ +#define SXACT_FLAG_DOOMED 0x00000008 /* will roll back */ /* * The following flag actually means that the flagged transaction has a * conflict out *to a transaction which committed ahead of it*. It's hard @@ -135,7 +135,7 @@ typedef struct PredXactListElementData { SHM_QUEUE link; SERIALIZABLEXACT sxact; -} PredXactListElementData; +} PredXactListElementData; typedef struct PredXactListElementData *PredXactListElement; @@ -153,28 +153,27 @@ typedef struct PredXactListData * but are not needed outside the predicate.c source file. Protected by * SerializableXactHashLock. */ - TransactionId SxactGlobalXmin; /* global xmin for active serializable - * transactions */ + TransactionId SxactGlobalXmin; /* global xmin for active serializable + * transactions */ int SxactGlobalXminCount; /* how many active serializable * transactions have this xmin */ - int WritableSxactCount; /* how many non-read-only serializable - * transactions are active */ - SerCommitSeqNo LastSxactCommitSeqNo; /* a strictly monotonically - * increasing number for - * commits of serializable - * transactions */ + int WritableSxactCount; /* how many non-read-only serializable + * transactions are active */ + SerCommitSeqNo LastSxactCommitSeqNo; /* a strictly monotonically + * increasing number for commits + * of serializable transactions */ /* Protected by SerializableXactHashLock. */ - SerCommitSeqNo CanPartialClearThrough; /* can clear predicate locks - * and inConflicts for - * committed transactions - * through this seq no */ + SerCommitSeqNo CanPartialClearThrough; /* can clear predicate locks and + * inConflicts for committed + * transactions through this seq + * no */ /* Protected by SerializableFinishedListLock. */ SerCommitSeqNo HavePartialClearedThrough; /* have cleared through this * seq no */ - SERIALIZABLEXACT *OldCommittedSxact; /* shared copy of dummy sxact */ + SERIALIZABLEXACT *OldCommittedSxact; /* shared copy of dummy sxact */ PredXactListElement element; -} PredXactListData; +} PredXactListData; typedef struct PredXactListData *PredXactList; @@ -198,7 +197,7 @@ typedef struct RWConflictData SHM_QUEUE inLink; /* link for list of conflicts in to a sxact */ SERIALIZABLEXACT *sxactOut; SERIALIZABLEXACT *sxactIn; -} RWConflictData; +} RWConflictData; typedef struct RWConflictData *RWConflict; @@ -209,7 +208,7 @@ typedef struct RWConflictPoolHeaderData { SHM_QUEUE availableList; RWConflict element; -} RWConflictPoolHeaderData; +} RWConflictPoolHeaderData; typedef struct RWConflictPoolHeaderData *RWConflictPoolHeader; @@ -477,4 +476,4 @@ extern PredicateLockData *GetPredicateLockStatusData(void); extern int GetSafeSnapshotBlockingPids(int blocked_pid, int *output, int output_size); -#endif /* PREDICATE_INTERNALS_H */ +#endif /* PREDICATE_INTERNALS_H */ diff --git a/src/include/storage/proc.h b/src/include/storage/proc.h index 0be7165d4f..4c8345db83 100644 --- a/src/include/storage/proc.h +++ b/src/include/storage/proc.h @@ -120,7 +120,7 @@ struct PGPROC * the distributed session */ #endif - bool isBackgroundWorker; /* true if background worker. */ + bool isBackgroundWorker; /* true if background worker. */ /* * While in hot standby mode, shows that a conflict signal has been sent @@ -188,7 +188,7 @@ struct PGPROC /* Lock manager data, recording fast-path locks taken by this backend. */ uint64 fpLockBits; /* lock modes held for each fast-path slot */ - Oid fpRelId[FP_LOCK_SLOTS_PER_BACKEND]; /* slots for rel oids */ + Oid fpRelId[FP_LOCK_SLOTS_PER_BACKEND]; /* slots for rel oids */ bool fpVXIDLock; /* are we holding a fast-path VXID lock? */ LocalTransactionId fpLocalTransactionId; /* lxid for fast-path VXID * lock */ @@ -198,7 +198,7 @@ struct PGPROC * leader to get the LWLock protecting these fields. */ PGPROC *lockGroupLeader; /* lock group leader, if I'm a member */ - dlist_head lockGroupMembers; /* list of members, if I'm a leader */ + dlist_head lockGroupMembers; /* list of members, if I'm a leader */ dlist_node lockGroupLink; /* my member link, if I'm a member */ }; @@ -331,4 +331,4 @@ extern PGPROC *AuxiliaryPidGetProc(int pid); extern void BecomeLockGroupLeader(void); extern bool BecomeLockGroupMember(PGPROC *leader, int pid); -#endif /* PROC_H */ +#endif /* PROC_H */ diff --git a/src/include/storage/procarray.h b/src/include/storage/procarray.h index 7dfe37f881..4e1622b174 100644 --- a/src/include/storage/procarray.h +++ b/src/include/storage/procarray.h @@ -38,16 +38,15 @@ typedef enum GlobalSnapshotSourceType * to avoid forcing to include proc.h when including procarray.h. So if you modify * PROC_XXX flags, you need to modify these flags. */ -#define PROCARRAY_VACUUM_FLAG 0x02 /* currently running - * lazy vacuum */ -#define PROCARRAY_ANALYZE_FLAG 0x04 /* currently running - * analyze */ -#define PROCARRAY_LOGICAL_DECODING_FLAG 0x10 /* currently doing - * logical decoding - * outside xact */ - -#define PROCARRAY_SLOTS_XMIN 0x20 /* replication slot - * xmin, catalog_xmin */ +#define PROCARRAY_VACUUM_FLAG 0x02 /* currently running lazy + * vacuum */ +#define PROCARRAY_ANALYZE_FLAG 0x04 /* currently running + * analyze */ +#define PROCARRAY_LOGICAL_DECODING_FLAG 0x10 /* currently doing logical + * decoding outside xact */ + +#define PROCARRAY_SLOTS_XMIN 0x20 /* replication slot xmin, + * catalog_xmin */ /* * Only flags in PROCARRAY_PROC_FLAGS_MASK are considered when matching * PGXACT->vacuumFlags. Other flags are used for different purposes and @@ -154,9 +153,9 @@ extern int GetFirstBackendId(int *numBackends, int *backends); #endif /* XCP */ extern void ProcArraySetReplicationSlotXmin(TransactionId xmin, - TransactionId catalog_xmin, bool already_locked); + TransactionId catalog_xmin, bool already_locked); extern void ProcArrayGetReplicationSlotXmin(TransactionId *xmin, TransactionId *catalog_xmin); -#endif /* PROCARRAY_H */ +#endif /* PROCARRAY_H */ diff --git a/src/include/storage/procsignal.h b/src/include/storage/procsignal.h index d58c1bede9..9b8f067a4e 100644 --- a/src/include/storage/procsignal.h +++ b/src/include/storage/procsignal.h @@ -46,8 +46,7 @@ typedef enum PROCSIG_PGXCPOOL_REFRESH, /* refresh local view of connection handles */ #endif PROCSIG_PARALLEL_MESSAGE, /* message from cooperating parallel backend */ - PROCSIG_WALSND_INIT_STOPPING, /* ask walsenders to prepare for - * shutdown */ + PROCSIG_WALSND_INIT_STOPPING, /* ask walsenders to prepare for shutdown */ /* Recovery conflict reasons */ PROCSIG_RECOVERY_CONFLICT_DATABASE, @@ -72,4 +71,4 @@ extern int SendProcSignal(pid_t pid, ProcSignalReason reason, extern void procsignal_sigusr1_handler(SIGNAL_ARGS); -#endif /* PROCSIGNAL_H */ +#endif /* PROCSIGNAL_H */ diff --git a/src/include/storage/reinit.h b/src/include/storage/reinit.h index 8c1b178de4..90e494e933 100644 --- a/src/include/storage/reinit.h +++ b/src/include/storage/reinit.h @@ -20,4 +20,4 @@ extern void ResetUnloggedRelations(int op); #define UNLOGGED_RELATION_CLEANUP 0x0001 #define UNLOGGED_RELATION_INIT 0x0002 -#endif /* REINIT_H */ +#endif /* REINIT_H */ diff --git a/src/include/storage/relfilenode.h b/src/include/storage/relfilenode.h index bdf3cecdfa..075ce6b077 100644 --- a/src/include/storage/relfilenode.h +++ b/src/include/storage/relfilenode.h @@ -101,4 +101,4 @@ typedef struct RelFileNodeBackend (node1).backend == (node2).backend && \ (node1).node.spcNode == (node2).node.spcNode) -#endif /* RELFILENODE_H */ +#endif /* RELFILENODE_H */ diff --git a/src/include/storage/shm_mq.h b/src/include/storage/shm_mq.h index 7a37535ab3..02a93e0222 100644 --- a/src/include/storage/shm_mq.h +++ b/src/include/storage/shm_mq.h @@ -82,4 +82,4 @@ extern shm_mq_result shm_mq_wait_for_attach(shm_mq_handle *mqh); /* Smallest possible queue. */ extern PGDLLIMPORT const Size shm_mq_minimum_size; -#endif /* SHM_MQ_H */ +#endif /* SHM_MQ_H */ diff --git a/src/include/storage/shm_toc.h b/src/include/storage/shm_toc.h index 9175a472d8..8ccd35d96b 100644 --- a/src/include/storage/shm_toc.h +++ b/src/include/storage/shm_toc.h @@ -55,4 +55,4 @@ typedef struct extern Size shm_toc_estimate(shm_toc_estimator *e); -#endif /* SHM_TOC_H */ +#endif /* SHM_TOC_H */ diff --git a/src/include/storage/shmem.h b/src/include/storage/shmem.h index 1961832c0f..c6993387ff 100644 --- a/src/include/storage/shmem.h +++ b/src/include/storage/shmem.h @@ -57,7 +57,7 @@ extern void RequestAddinShmemSpace(Size size); /* this is a hash bucket in the shmem index table */ typedef struct { - char key[SHMEM_INDEX_KEYSIZE]; /* string name */ + char key[SHMEM_INDEX_KEYSIZE]; /* string name */ void *location; /* location in shared mem */ Size size; /* # bytes allocated for the structure */ } ShmemIndexEnt; @@ -77,4 +77,4 @@ extern Pointer SHMQueuePrev(const SHM_QUEUE *queue, const SHM_QUEUE *curElem, extern bool SHMQueueEmpty(const SHM_QUEUE *queue); extern bool SHMQueueIsDetached(const SHM_QUEUE *queue); -#endif /* SHMEM_H */ +#endif /* SHMEM_H */ diff --git a/src/include/storage/sinval.h b/src/include/storage/sinval.h index 6a3db9580f..84c0b02da0 100644 --- a/src/include/storage/sinval.h +++ b/src/include/storage/sinval.h @@ -130,7 +130,7 @@ extern volatile sig_atomic_t catchupInterruptPending; extern void SendSharedInvalidMessages(const SharedInvalidationMessage *msgs, int n); extern void ReceiveSharedInvalidMessages( - void (*invalFunction) (SharedInvalidationMessage *msg), + void (*invalFunction) (SharedInvalidationMessage *msg), void (*resetFunction) (void)); /* signal handler for catchup events (PROCSIG_CATCHUP_INTERRUPT) */ @@ -151,4 +151,4 @@ extern void ProcessCommittedInvalidationMessages(SharedInvalidationMessage *msgs extern void LocalExecuteInvalidationMessage(SharedInvalidationMessage *msg); -#endif /* SINVAL_H */ +#endif /* SINVAL_H */ diff --git a/src/include/storage/sinvaladt.h b/src/include/storage/sinvaladt.h index 07ac2f8c85..751735fc9a 100644 --- a/src/include/storage/sinvaladt.h +++ b/src/include/storage/sinvaladt.h @@ -40,4 +40,4 @@ extern void SICleanupQueue(bool callerHasWriteLock, int minFree); extern LocalTransactionId GetNextLocalTransactionId(void); -#endif /* SINVALADT_H */ +#endif /* SINVALADT_H */ diff --git a/src/include/storage/smgr.h b/src/include/storage/smgr.h index 91a97f84b8..27c33af846 100644 --- a/src/include/storage/smgr.h +++ b/src/include/storage/smgr.h @@ -41,7 +41,7 @@ typedef struct SMgrRelationData { /* rnode is the hashtable lookup key, so it must be first! */ - RelFileNodeBackend smgr_rnode; /* relation physical identifier */ + RelFileNodeBackend smgr_rnode; /* relation physical identifier */ /* pointer to owning pointer, or NULL if none */ struct SMgrRelationData **smgr_owner; @@ -54,7 +54,7 @@ typedef struct SMgrRelationData * happens. In all three cases, InvalidBlockNumber means "unknown". */ BlockNumber smgr_targblock; /* current insertion target block */ - BlockNumber smgr_fsm_nblocks; /* last known size of fsm fork */ + BlockNumber smgr_fsm_nblocks; /* last known size of fsm fork */ BlockNumber smgr_vm_nblocks; /* last known size of vm fork */ /* additional public fields may someday exist here */ @@ -151,4 +151,4 @@ extern void RememberFsyncRequest(RelFileNode rnode, ForkNumber forknum, extern void ForgetRelationFsyncRequests(RelFileNode rnode, ForkNumber forknum); extern void ForgetDatabaseFsyncRequests(Oid dbid); -#endif /* SMGR_H */ +#endif /* SMGR_H */ diff --git a/src/include/storage/spin.h b/src/include/storage/spin.h index 8987c90537..66698645c2 100644 --- a/src/include/storage/spin.h +++ b/src/include/storage/spin.h @@ -74,4 +74,4 @@ extern void SpinlockSemaInit(void); extern PGSemaphore *SpinlockSemaArray; #endif -#endif /* SPIN_H */ +#endif /* SPIN_H */ diff --git a/src/include/storage/standby.h b/src/include/storage/standby.h index 3ecc446083..f5404b4c1f 100644 --- a/src/include/storage/standby.h +++ b/src/include/storage/standby.h @@ -73,7 +73,7 @@ typedef struct RunningTransactionsData int subxcnt; /* # of subxact ids in xids[] */ bool subxid_overflow; /* snapshot overflowed, subxids missing */ TransactionId nextXid; /* copy of ShmemVariableCache->nextXid */ - TransactionId oldestRunningXid; /* *not* oldestXmin */ + TransactionId oldestRunningXid; /* *not* oldestXmin */ TransactionId latestCompletedXid; /* so we can set xmax */ TransactionId *xids; /* array of (sub)xids still running */ @@ -88,4 +88,4 @@ extern XLogRecPtr LogStandbySnapshot(void); extern void LogStandbyInvalidations(int nmsgs, SharedInvalidationMessage *msgs, bool relcacheInitFileInval); -#endif /* STANDBY_H */ +#endif /* STANDBY_H */ diff --git a/src/include/storage/standbydefs.h b/src/include/storage/standbydefs.h index f8444c787a..a0af6788e9 100644 --- a/src/include/storage/standbydefs.h +++ b/src/include/storage/standbydefs.h @@ -50,7 +50,7 @@ typedef struct xl_running_xacts int subxcnt; /* # of subxact ids in xids[] */ bool subxid_overflow; /* snapshot overflowed, subxids missing */ TransactionId nextXid; /* copy of ShmemVariableCache->nextXid */ - TransactionId oldestRunningXid; /* *not* oldestXmin */ + TransactionId oldestRunningXid; /* *not* oldestXmin */ TransactionId latestCompletedXid; /* so we can set xmax */ TransactionId xids[FLEXIBLE_ARRAY_MEMBER]; @@ -71,4 +71,4 @@ typedef struct xl_invalidations #define MinSizeOfInvalidations offsetof(xl_invalidations, msgs) -#endif /* STANDBYDEFS_H */ +#endif /* STANDBYDEFS_H */ diff --git a/src/include/tcop/deparse_utility.h b/src/include/tcop/deparse_utility.h index f0b25bea90..9c4e608934 100644 --- a/src/include/tcop/deparse_utility.h +++ b/src/include/tcop/deparse_utility.h @@ -102,4 +102,4 @@ typedef struct CollectedCommand } d; } CollectedCommand; -#endif /* DEPARSE_UTILITY_H */ +#endif /* DEPARSE_UTILITY_H */ diff --git a/src/include/tcop/dest.h b/src/include/tcop/dest.h index 622d35b346..445178307d 100644 --- a/src/include/tcop/dest.h +++ b/src/include/tcop/dest.h @@ -120,11 +120,11 @@ struct _DestReceiver { /* Called for each tuple to be output: */ bool (*receiveSlot) (TupleTableSlot *slot, - DestReceiver *self); + DestReceiver *self); /* Per-executor-run initialization and shutdown: */ void (*rStartup) (DestReceiver *self, - int operation, - TupleDesc typeinfo); + int operation, + TupleDesc typeinfo); void (*rShutdown) (DestReceiver *self); /* Destroy the receiver object itself (if dynamically allocated) */ void (*rDestroy) (DestReceiver *self); @@ -133,7 +133,7 @@ struct _DestReceiver /* Private fields might appear beyond this point... */ }; -extern DestReceiver *None_Receiver; /* permanent receiver for DestNone */ +extern DestReceiver *None_Receiver; /* permanent receiver for DestNone */ /* The primary destination management functions */ @@ -146,4 +146,4 @@ extern void EndCommand(const char *commandTag, CommandDest dest); extern void NullCommand(CommandDest dest); extern void ReadyForQuery(CommandDest dest); -#endif /* DEST_H */ +#endif /* DEST_H */ diff --git a/src/include/tcop/fastpath.h b/src/include/tcop/fastpath.h index 81d94913db..4a7c35f1a9 100644 --- a/src/include/tcop/fastpath.h +++ b/src/include/tcop/fastpath.h @@ -18,4 +18,4 @@ extern int GetOldFunctionMessage(StringInfo buf); extern void HandleFunctionRequest(StringInfo msgBuf); -#endif /* FASTPATH_H */ +#endif /* FASTPATH_H */ diff --git a/src/include/tcop/pquery.h b/src/include/tcop/pquery.h index e8ec5d0f8f..0d787dd99c 100644 --- a/src/include/tcop/pquery.h +++ b/src/include/tcop/pquery.h @@ -48,4 +48,4 @@ extern int AdvanceProducingPortal(Portal portal, bool can_wait); extern void cleanupClosedProducers(void); #endif -#endif /* PQUERY_H */ +#endif /* PQUERY_H */ diff --git a/src/include/tcop/tcopprot.h b/src/include/tcop/tcopprot.h index 8700e5d88e..fe1a9b00fe 100644 --- a/src/include/tcop/tcopprot.h +++ b/src/include/tcop/tcopprot.h @@ -96,4 +96,4 @@ extern bool set_plan_disabling_options(const char *arg, GucContext context, GucSource source); extern const char *get_stats_option_name(const char *arg); -#endif /* TCOPPROT_H */ +#endif /* TCOPPROT_H */ diff --git a/src/include/tcop/utility.h b/src/include/tcop/utility.h index d52f3e8525..2f09a939d9 100644 --- a/src/include/tcop/utility.h +++ b/src/include/tcop/utility.h @@ -25,12 +25,12 @@ typedef enum /* Hook for plugins to get control in ProcessUtility() */ typedef void (*ProcessUtility_hook_type) (PlannedStmt *pstmt, - const char *queryString, ProcessUtilityContext context, - ParamListInfo params, - QueryEnvironment *queryEnv, - DestReceiver *dest, - bool sentToRemote, - char *completionTag); + const char *queryString, ProcessUtilityContext context, + ParamListInfo params, + QueryEnvironment *queryEnv, + DestReceiver *dest, + bool sentToRemote, + char *completionTag); extern PGDLLIMPORT ProcessUtility_hook_type ProcessUtility_hook; extern void ProcessUtility(PlannedStmt *pstmt, const char *queryString, @@ -62,4 +62,4 @@ extern bool CommandIsReadOnly(PlannedStmt *pstmt); extern bool pgxc_lock_for_utility_stmt(Node *parsetree); #endif -#endif /* UTILITY_H */ +#endif /* UTILITY_H */ diff --git a/src/include/tsearch/ts_cache.h b/src/include/tsearch/ts_cache.h index 80b8a079ed..abff0fdfcc 100644 --- a/src/include/tsearch/ts_cache.h +++ b/src/include/tsearch/ts_cache.h @@ -95,4 +95,4 @@ extern Oid getTSCurrentConfig(bool emitError); extern bool check_TSCurrentConfig(char **newval, void **extra, GucSource source); extern void assign_TSCurrentConfig(const char *newval, void *extra); -#endif /* TS_CACHE_H */ +#endif /* TS_CACHE_H */ diff --git a/src/include/tsearch/ts_locale.h b/src/include/tsearch/ts_locale.h index afcf2b93de..c32f0743aa 100644 --- a/src/include/tsearch/ts_locale.h +++ b/src/include/tsearch/ts_locale.h @@ -61,7 +61,7 @@ extern int t_isprint(const char *ptr); #define t_iseq(x,c) (TOUCHAR(x) == (unsigned char) (c)) #define COPYCHAR(d,s) (*((unsigned char *) (d)) = TOUCHAR(s)) -#endif /* USE_WIDE_UPPER_LOWER */ +#endif /* USE_WIDE_UPPER_LOWER */ extern char *lowerstr(const char *str); extern char *lowerstr_with_len(const char *str, int len); @@ -73,4 +73,4 @@ extern void tsearch_readline_end(tsearch_readline_state *stp); extern char *t_readline(FILE *fp); -#endif /* __TSLOCALE_H__ */ +#endif /* __TSLOCALE_H__ */ diff --git a/src/include/tsearch/ts_public.h b/src/include/tsearch/ts_public.h index 4c190b22e8..94ba7fcb20 100644 --- a/src/include/tsearch/ts_public.h +++ b/src/include/tsearch/ts_public.h @@ -129,4 +129,4 @@ typedef struct * getnext == true */ } DictSubState; -#endif /* _PG_TS_PUBLIC_H_ */ +#endif /* _PG_TS_PUBLIC_H_ */ diff --git a/src/include/tsearch/ts_type.h b/src/include/tsearch/ts_type.h index 873e2e1856..2885bc0153 100644 --- a/src/include/tsearch/ts_type.h +++ b/src/include/tsearch/ts_type.h @@ -248,4 +248,4 @@ typedef TSQueryData *TSQuery; #define PG_GETARG_TSQUERY_COPY(n) DatumGetTSQueryCopy(PG_GETARG_DATUM(n)) #define PG_RETURN_TSQUERY(x) return TSQueryGetDatum(x) -#endif /* _PG_TSTYPE_H_ */ +#endif /* _PG_TSTYPE_H_ */ diff --git a/src/include/tsearch/ts_utils.h b/src/include/tsearch/ts_utils.h index 20d90b12fd..3312353026 100644 --- a/src/include/tsearch/ts_utils.h +++ b/src/include/tsearch/ts_utils.h @@ -41,11 +41,10 @@ struct TSQueryParserStateData; /* private in backend/utils/adt/tsquery.c */ typedef struct TSQueryParserStateData *TSQueryParserState; typedef void (*PushFunction) (Datum opaque, TSQueryParserState state, - char *token, int tokenlen, - int16 tokenweights, /* bitmap as described - * in QueryOperand - * struct */ - bool prefix); + char *token, int tokenlen, + int16 tokenweights, /* bitmap as described in + * QueryOperand struct */ + bool prefix); extern TSQuery parse_tsquery(char *buf, PushFunction pushval, @@ -152,7 +151,7 @@ typedef struct ExecPhraseData * it as zeroes if position data is not available. */ typedef bool (*TSExecuteCallback) (void *arg, QueryOperand *val, - ExecPhraseData *data); + ExecPhraseData *data); /* * Flag bits for TS_execute @@ -237,4 +236,4 @@ extern TSQuerySign makeTSQuerySign(TSQuery a); extern QTNode *findsubquery(QTNode *root, QTNode *ex, QTNode *subs, bool *isfind); -#endif /* _PG_TS_UTILS_H_ */ +#endif /* _PG_TS_UTILS_H_ */ diff --git a/src/include/utils/acl.h b/src/include/utils/acl.h index 2487020ec1..43273eaab5 100644 --- a/src/include/utils/acl.h +++ b/src/include/utils/acl.h @@ -127,11 +127,11 @@ typedef ArrayType Acl; * External representations of the privilege bits --- aclitemin/aclitemout * represent each possible privilege bit with a distinct 1-character code */ -#define ACL_INSERT_CHR 'a' /* formerly known as "append" */ -#define ACL_SELECT_CHR 'r' /* formerly known as "read" */ -#define ACL_UPDATE_CHR 'w' /* formerly known as "write" */ +#define ACL_INSERT_CHR 'a' /* formerly known as "append" */ +#define ACL_SELECT_CHR 'r' /* formerly known as "read" */ +#define ACL_UPDATE_CHR 'w' /* formerly known as "write" */ #define ACL_DELETE_CHR 'd' -#define ACL_TRUNCATE_CHR 'D' /* super-delete, as it were */ +#define ACL_TRUNCATE_CHR 'D' /* super-delete, as it were */ #define ACL_REFERENCES_CHR 'x' #define ACL_TRIGGER_CHR 't' #define ACL_EXECUTE_CHR 'X' @@ -265,7 +265,7 @@ extern AclMode pg_proc_aclmask(Oid proc_oid, Oid roleid, extern AclMode pg_language_aclmask(Oid lang_oid, Oid roleid, AclMode mask, AclMaskHow how); extern AclMode pg_largeobject_aclmask_snapshot(Oid lobj_oid, Oid roleid, - AclMode mask, AclMaskHow how, Snapshot snapshot); + AclMode mask, AclMaskHow how, Snapshot snapshot); extern AclMode pg_namespace_aclmask(Oid nsp_oid, Oid roleid, AclMode mask, AclMaskHow how); extern AclMode pg_tablespace_aclmask(Oid spc_oid, Oid roleid, @@ -331,4 +331,4 @@ extern bool pg_statistics_object_ownercheck(Oid stat_oid, Oid roleid); extern bool has_createrole_privilege(Oid roleid); extern bool has_bypassrls_privilege(Oid roleid); -#endif /* ACL_H */ +#endif /* ACL_H */ diff --git a/src/include/utils/aclchk_internal.h b/src/include/utils/aclchk_internal.h index 0e50f73aab..3374edb638 100644 --- a/src/include/utils/aclchk_internal.h +++ b/src/include/utils/aclchk_internal.h @@ -42,4 +42,4 @@ typedef struct } InternalGrant; -#endif /* ACLCHK_INTERNAL_H */ +#endif /* ACLCHK_INTERNAL_H */ diff --git a/src/include/utils/array.h b/src/include/utils/array.h index 552c08f0d5..61a67a21e3 100644 --- a/src/include/utils/array.h +++ b/src/include/utils/array.h @@ -443,4 +443,4 @@ extern ExpandedArrayHeader *DatumGetExpandedArrayX(Datum d, extern AnyArrayType *DatumGetAnyArray(Datum d); extern void deconstruct_expanded_array(ExpandedArrayHeader *eah); -#endif /* ARRAY_H */ +#endif /* ARRAY_H */ diff --git a/src/include/utils/arrayaccess.h b/src/include/utils/arrayaccess.h index 6148bdf834..7655c80bed 100644 --- a/src/include/utils/arrayaccess.h +++ b/src/include/utils/arrayaccess.h @@ -115,4 +115,4 @@ array_iter_next(array_iter *it, bool *isnull, int i, return ret; } -#endif /* ARRAYACCESS_H */ +#endif /* ARRAYACCESS_H */ diff --git a/src/include/utils/ascii.h b/src/include/utils/ascii.h index 3771e1acab..d3b183f11f 100644 --- a/src/include/utils/ascii.h +++ b/src/include/utils/ascii.h @@ -13,4 +13,4 @@ extern void ascii_safe_strlcpy(char *dest, const char *src, size_t destsiz); -#endif /* _ASCII_H_ */ +#endif /* _ASCII_H_ */ diff --git a/src/include/utils/attoptcache.h b/src/include/utils/attoptcache.h index 7f2334b4cd..4eef793181 100644 --- a/src/include/utils/attoptcache.h +++ b/src/include/utils/attoptcache.h @@ -25,4 +25,4 @@ typedef struct AttributeOpts AttributeOpts *get_attribute_options(Oid spcid, int attnum); -#endif /* ATTOPTCACHE_H */ +#endif /* ATTOPTCACHE_H */ diff --git a/src/include/utils/backend_random.h b/src/include/utils/backend_random.h index 31602f250d..9781aea0ac 100644 --- a/src/include/utils/backend_random.h +++ b/src/include/utils/backend_random.h @@ -16,4 +16,4 @@ extern Size BackendRandomShmemSize(void); extern void BackendRandomShmemInit(void); extern bool pg_backend_random(char *dst, int len); -#endif /* BACKEND_RANDOM_H */ +#endif /* BACKEND_RANDOM_H */ diff --git a/src/include/utils/builtins.h b/src/include/utils/builtins.h index ea93c922f1..586dc44978 100644 --- a/src/include/utils/builtins.h +++ b/src/include/utils/builtins.h @@ -153,4 +153,4 @@ extern Datum pg_msgmodule_enable(PG_FUNCTION_ARGS); extern Datum pg_msgmodule_disable(PG_FUNCTION_ARGS); extern Datum pg_msgmodule_enable_all(PG_FUNCTION_ARGS); extern Datum pg_msgmodule_disable_all(PG_FUNCTION_ARGS); -#endif /* BUILTINS_H */ +#endif /* BUILTINS_H */ diff --git a/src/include/utils/bytea.h b/src/include/utils/bytea.h index 818e65707f..d7bd30842e 100644 --- a/src/include/utils/bytea.h +++ b/src/include/utils/bytea.h @@ -21,8 +21,8 @@ typedef enum { BYTEA_OUTPUT_ESCAPE, BYTEA_OUTPUT_HEX -} ByteaOutputType; +} ByteaOutputType; extern int bytea_output; /* ByteaOutputType, but int for GUC enum */ -#endif /* BYTEA_H */ +#endif /* BYTEA_H */ diff --git a/src/include/utils/cash.h b/src/include/utils/cash.h index 84083677e1..2e332d83b1 100644 --- a/src/include/utils/cash.h +++ b/src/include/utils/cash.h @@ -22,4 +22,4 @@ typedef int64 Cash; #define PG_GETARG_CASH(n) DatumGetCash(PG_GETARG_DATUM(n)) #define PG_RETURN_CASH(x) return CashGetDatum(x) -#endif /* CASH_H */ +#endif /* CASH_H */ diff --git a/src/include/utils/catcache.h b/src/include/utils/catcache.h index 5add424e5e..f8ebc903d3 100644 --- a/src/include/utils/catcache.h +++ b/src/include/utils/catcache.h @@ -46,10 +46,10 @@ typedef struct catcache int cc_ntup; /* # of tuples currently in this cache */ int cc_nbuckets; /* # of hash buckets in this cache */ int cc_nkeys; /* # of keys (1..CATCACHE_MAXKEYS) */ - int cc_key[CATCACHE_MAXKEYS]; /* AttrNumber of each key */ + int cc_key[CATCACHE_MAXKEYS]; /* AttrNumber of each key */ PGFunction cc_hashfunc[CATCACHE_MAXKEYS]; /* hash function for each key */ - ScanKeyData cc_skey[CATCACHE_MAXKEYS]; /* precomputed key info for - * heap scans */ + ScanKeyData cc_skey[CATCACHE_MAXKEYS]; /* precomputed key info for heap + * scans */ bool cc_isname[CATCACHE_MAXKEYS]; /* flag "name" key columns */ dlist_head cc_lists; /* list of CatCList structs */ dlist_head *cc_bucket; /* hash buckets */ @@ -199,4 +199,4 @@ extern void PrepareToInvalidateCacheTuple(Relation relation, extern void PrintCatCacheLeakWarning(HeapTuple tuple); extern void PrintCatCacheListLeakWarning(CatCList *list); -#endif /* CATCACHE_H */ +#endif /* CATCACHE_H */ diff --git a/src/include/utils/combocid.h b/src/include/utils/combocid.h index 1cb0e74275..6d8be8bf0f 100644 --- a/src/include/utils/combocid.h +++ b/src/include/utils/combocid.h @@ -25,4 +25,4 @@ extern void RestoreComboCIDState(char *comboCIDstate); extern void SerializeComboCIDState(Size maxsize, char *start_address); extern Size EstimateComboCIDStateSpace(void); -#endif /* COMBOCID_H */ +#endif /* COMBOCID_H */ diff --git a/src/include/utils/date.h b/src/include/utils/date.h index 309a581853..0736a72946 100644 --- a/src/include/utils/date.h +++ b/src/include/utils/date.h @@ -74,4 +74,4 @@ extern DateADT GetSQLCurrentDate(void); extern TimeTzADT *GetSQLCurrentTime(int32 typmod); extern TimeADT GetSQLLocalTime(int32 typmod); -#endif /* DATE_H */ +#endif /* DATE_H */ diff --git a/src/include/utils/datetime.h b/src/include/utils/datetime.h index fb7885bf34..7968569fda 100644 --- a/src/include/utils/datetime.h +++ b/src/include/utils/datetime.h @@ -259,7 +259,7 @@ do { \ * Include check for leap year. */ -extern const char *const months[]; /* months (3-char abbreviations) */ +extern const char *const months[]; /* months (3-char abbreviations) */ extern const char *const days[]; /* days (full names) */ extern const int day_tab[2][13]; @@ -286,8 +286,8 @@ extern const int day_tab[2][13]; #define DTERR_TZDISP_OVERFLOW (-5) -extern void GetCurrentDateTime(struct pg_tm * tm); -extern void GetCurrentTimeUsec(struct pg_tm * tm, fsec_t *fsec, int *tzp); +extern void GetCurrentDateTime(struct pg_tm *tm); +extern void GetCurrentTimeUsec(struct pg_tm *tm, fsec_t *fsec, int *tzp); extern void j2date(int jd, int *year, int *month, int *day); extern int date2j(int year, int month, int day); @@ -296,32 +296,32 @@ extern int ParseDateTime(const char *timestr, char *workbuf, size_t buflen, int maxfields, int *numfields); extern int DecodeDateTime(char **field, int *ftype, int nf, int *dtype, - struct pg_tm * tm, fsec_t *fsec, int *tzp); + struct pg_tm *tm, fsec_t *fsec, int *tzp); extern int DecodeTimezone(char *str, int *tzp); extern int DecodeTimeOnly(char **field, int *ftype, int nf, int *dtype, - struct pg_tm * tm, fsec_t *fsec, int *tzp); + struct pg_tm *tm, fsec_t *fsec, int *tzp); extern int DecodeInterval(char **field, int *ftype, int nf, int range, - int *dtype, struct pg_tm * tm, fsec_t *fsec); + int *dtype, struct pg_tm *tm, fsec_t *fsec); extern int DecodeISO8601Interval(char *str, - int *dtype, struct pg_tm * tm, fsec_t *fsec); + int *dtype, struct pg_tm *tm, fsec_t *fsec); extern void DateTimeParseError(int dterr, const char *str, const char *datatype) pg_attribute_noreturn(); -extern int DetermineTimeZoneOffset(struct pg_tm * tm, pg_tz *tzp); -extern int DetermineTimeZoneAbbrevOffset(struct pg_tm * tm, const char *abbr, pg_tz *tzp); +extern int DetermineTimeZoneOffset(struct pg_tm *tm, pg_tz *tzp); +extern int DetermineTimeZoneAbbrevOffset(struct pg_tm *tm, const char *abbr, pg_tz *tzp); extern int DetermineTimeZoneAbbrevOffsetTS(TimestampTz ts, const char *abbr, pg_tz *tzp, int *isdst); -extern void EncodeDateOnly(struct pg_tm * tm, int style, char *str); -extern void EncodeTimeOnly(struct pg_tm * tm, fsec_t fsec, bool print_tz, int tz, int style, char *str); -extern void EncodeDateTime(struct pg_tm * tm, fsec_t fsec, bool print_tz, int tz, const char *tzn, int style, char *str); -extern void EncodeInterval(struct pg_tm * tm, fsec_t fsec, int style, char *str); +extern void EncodeDateOnly(struct pg_tm *tm, int style, char *str); +extern void EncodeTimeOnly(struct pg_tm *tm, fsec_t fsec, bool print_tz, int tz, int style, char *str); +extern void EncodeDateTime(struct pg_tm *tm, fsec_t fsec, bool print_tz, int tz, const char *tzn, int style, char *str); +extern void EncodeInterval(struct pg_tm *tm, fsec_t fsec, int style, char *str); extern void EncodeSpecialTimestamp(Timestamp dt, char *str); extern int ValidateDate(int fmask, bool isjulian, bool is2digits, bool bc, - struct pg_tm * tm); + struct pg_tm *tm); extern int DecodeTimezoneAbbrev(int field, char *lowtoken, int *offset, pg_tz **tz); @@ -338,4 +338,4 @@ extern TimeZoneAbbrevTable *ConvertTimeZoneAbbrevs(struct tzEntry *abbrevs, int n); extern void InstallTimeZoneAbbrevs(TimeZoneAbbrevTable *tbl); -#endif /* DATETIME_H */ +#endif /* DATETIME_H */ diff --git a/src/include/utils/datum.h b/src/include/utils/datum.h index a8a9ea6d19..d2f0f9ed51 100644 --- a/src/include/utils/datum.h +++ b/src/include/utils/datum.h @@ -56,4 +56,4 @@ extern void datumSerialize(Datum value, bool isnull, bool typByVal, int typLen, char **start_address); extern Datum datumRestore(char **start_address, bool *isnull); -#endif /* DATUM_H */ +#endif /* DATUM_H */ diff --git a/src/include/utils/dsa.h b/src/include/utils/dsa.h index f084443409..516ef610f0 100644 --- a/src/include/utils/dsa.h +++ b/src/include/utils/dsa.h @@ -122,4 +122,4 @@ extern void *dsa_get_address(dsa_area *area, dsa_pointer dp); extern void dsa_trim(dsa_area *area); extern void dsa_dump(dsa_area *area); -#endif /* DSA_H */ +#endif /* DSA_H */ diff --git a/src/include/utils/dynahash.h b/src/include/utils/dynahash.h index eee5cce928..8e03245a03 100644 --- a/src/include/utils/dynahash.h +++ b/src/include/utils/dynahash.h @@ -16,4 +16,4 @@ extern int my_log2(long num); -#endif /* DYNAHASH_H */ +#endif /* DYNAHASH_H */ diff --git a/src/include/utils/dynamic_loader.h b/src/include/utils/dynamic_loader.h index 987f21a362..6c9287b611 100644 --- a/src/include/utils/dynamic_loader.h +++ b/src/include/utils/dynamic_loader.h @@ -22,4 +22,4 @@ extern PGFunction pg_dlsym(void *handle, char *funcname); extern void pg_dlclose(void *handle); extern char *pg_dlerror(void); -#endif /* DYNAMIC_LOADER_H */ +#endif /* DYNAMIC_LOADER_H */ diff --git a/src/include/utils/elog.h b/src/include/utils/elog.h index b56e444b5e..df9e7a6901 100644 --- a/src/include/utils/elog.h +++ b/src/include/utils/elog.h @@ -27,9 +27,9 @@ * server log by default. */ #define LOG_SERVER_ONLY 16 /* Same as LOG for server reporting, but never * sent to client. */ -#define COMMERROR LOG_SERVER_ONLY /* Client communication problems; same - * as LOG for server reporting, but - * never sent to client. */ +#define COMMERROR LOG_SERVER_ONLY /* Client communication problems; same as + * LOG for server reporting, but never + * sent to client. */ #define INFO 17 /* Messages specifically requested by user (eg * VACUUM VERBOSE output); always sent to * client regardless of client_min_messages, @@ -137,7 +137,7 @@ if (elevel_ >= ERROR) \ pg_unreachable(); \ } while(0) -#endif /* HAVE__BUILTIN_CONSTANT_P */ +#endif /* HAVE__BUILTIN_CONSTANT_P */ #endif #define ereport(elevel, rest) \ @@ -162,7 +162,7 @@ extern int errmsg(const char *fmt,...) pg_attribute_printf(1, 2); extern int errmsg_internal(const char *fmt,...) pg_attribute_printf(1, 2); extern int errmsg_plural(const char *fmt_singular, const char *fmt_plural, - unsigned long n,...) pg_attribute_printf(1, 4) pg_attribute_printf(2, 4); + unsigned long n,...) pg_attribute_printf(1, 4) pg_attribute_printf(2, 4); extern int errdetail(const char *fmt,...) pg_attribute_printf(1, 2); extern int errdetail_internal(const char *fmt,...) pg_attribute_printf(1, 2); @@ -171,10 +171,10 @@ extern int errdetail_log(const char *fmt,...) pg_attribute_printf(1, 2); extern int errdetail_log_plural(const char *fmt_singular, const char *fmt_plural, - unsigned long n,...) pg_attribute_printf(1, 4) pg_attribute_printf(2, 4); + unsigned long n,...) pg_attribute_printf(1, 4) pg_attribute_printf(2, 4); extern int errdetail_plural(const char *fmt_singular, const char *fmt_plural, - unsigned long n,...) pg_attribute_printf(1, 4) pg_attribute_printf(2, 4); + unsigned long n,...) pg_attribute_printf(1, 4) pg_attribute_printf(2, 4); extern int errhint(const char *fmt,...) pg_attribute_printf(1, 2); @@ -268,14 +268,14 @@ extern int getinternalerrposition(void); pg_unreachable(); \ } \ } while(0) -#endif /* HAVE__BUILTIN_CONSTANT_P */ +#endif /* HAVE__BUILTIN_CONSTANT_P */ #else /* !HAVE__VA_ARGS */ #define elog \ do { \ elog_start(__FILE__, __LINE__, PG_FUNCNAME_MACRO); \ } while (0); \ elog_finish -#endif /* HAVE__VA_ARGS */ +#endif /* HAVE__VA_ARGS */ #endif extern void elog_start(const char *filename, int lineno, @@ -391,8 +391,8 @@ extern PGDLLIMPORT sigjmp_buf *PG_exception_stack; typedef struct ErrorData { int elevel; /* error level */ - bool output_to_server; /* will report to server log? */ - bool output_to_client; /* will report to client? */ + bool output_to_server; /* will report to server log? */ + bool output_to_client; /* will report to client? */ bool show_funcname; /* true to force funcname inclusion */ bool hide_stmt; /* true to prevent STATEMENT: inclusion */ bool hide_ctx; /* true to prevent CONTEXT: inclusion */ @@ -459,7 +459,7 @@ typedef enum PGERROR_TERSE, /* single-line error messages */ PGERROR_DEFAULT, /* recommended style */ PGERROR_VERBOSE /* all the facts, ma'am */ -} PGErrorVerbosity; +} PGErrorVerbosity; extern int Log_error_verbosity; extern char *Log_line_prefix; @@ -490,4 +490,4 @@ extern void set_syslog_parameters(const char *ident, int facility); */ extern void write_stderr(const char *fmt,...) pg_attribute_printf(1, 2); -#endif /* ELOG_H */ +#endif /* ELOG_H */ diff --git a/src/include/utils/evtcache.h b/src/include/utils/evtcache.h index f6ea163df3..9774eac5a6 100644 --- a/src/include/utils/evtcache.h +++ b/src/include/utils/evtcache.h @@ -34,4 +34,4 @@ typedef struct extern List *EventCacheLookup(EventTriggerEvent event); -#endif /* EVTCACHE_H */ +#endif /* EVTCACHE_H */ diff --git a/src/include/utils/expandeddatum.h b/src/include/utils/expandeddatum.h index f853a13e6e..7116b860cc 100644 --- a/src/include/utils/expandeddatum.h +++ b/src/include/utils/expandeddatum.h @@ -66,7 +66,7 @@ */ typedef Size (*EOM_get_flat_size_method) (ExpandedObjectHeader *eohptr); typedef void (*EOM_flatten_into_method) (ExpandedObjectHeader *eohptr, - void *result, Size allocated_size); + void *result, Size allocated_size); /* Struct of function pointers for an expanded object's methods */ typedef struct ExpandedObjectMethods @@ -156,4 +156,4 @@ extern Datum MakeExpandedObjectReadOnlyInternal(Datum d); extern Datum TransferExpandedObject(Datum d, MemoryContext new_parent); extern void DeleteExpandedObject(Datum d); -#endif /* EXPANDEDDATUM_H */ +#endif /* EXPANDEDDATUM_H */ diff --git a/src/include/utils/fmgrtab.h b/src/include/utils/fmgrtab.h index 414cd03952..6130ef8f9c 100644 --- a/src/include/utils/fmgrtab.h +++ b/src/include/utils/fmgrtab.h @@ -36,4 +36,4 @@ extern const FmgrBuiltin fmgr_builtins[]; extern const int fmgr_nbuiltins; /* number of entries in table */ -#endif /* FMGRTAB_H */ +#endif /* FMGRTAB_H */ diff --git a/src/include/utils/freepage.h b/src/include/utils/freepage.h index 78caa5369b..c370c733ee 100644 --- a/src/include/utils/freepage.h +++ b/src/include/utils/freepage.h @@ -96,4 +96,4 @@ extern void FreePageManagerPut(FreePageManager *fpm, Size first_page, Size npages); extern char *FreePageManagerDump(FreePageManager *fpm); -#endif /* FREEPAGE_H */ +#endif /* FREEPAGE_H */ diff --git a/src/include/utils/geo_decls.h b/src/include/utils/geo_decls.h index 9b530dbe3d..44c6381b85 100644 --- a/src/include/utils/geo_decls.h +++ b/src/include/utils/geo_decls.h @@ -183,4 +183,4 @@ extern double point_dt(Point *pt1, Point *pt2); extern double point_sl(Point *pt1, Point *pt2); extern double pg_hypot(double x, double y); -#endif /* GEO_DECLS_H */ +#endif /* GEO_DECLS_H */ diff --git a/src/include/utils/guc.h b/src/include/utils/guc.h index 144281aa24..7917832a55 100644 --- a/src/include/utils/guc.h +++ b/src/include/utils/guc.h @@ -213,8 +213,8 @@ typedef enum #define GUC_SUPERUSER_ONLY 0x0100 /* show only to superusers */ #define GUC_IS_NAME 0x0200 /* limit string to NAMEDATALEN-1 */ #define GUC_NOT_WHILE_SEC_REST 0x0400 /* can't set if security restricted */ -#define GUC_DISALLOW_IN_AUTO_FILE 0x0800 /* can't set in - * PG_AUTOCONF_FILENAME */ +#define GUC_DISALLOW_IN_AUTO_FILE 0x0800 /* can't set in + * PG_AUTOCONF_FILENAME */ #define GUC_UNIT_KB 0x1000 /* value is in kilobytes */ #define GUC_UNIT_BLOCKS 0x2000 /* value is in blocks */ @@ -345,7 +345,7 @@ extern void DefineCustomEnumVariable( const char *long_desc, int *valueAddr, int bootValue, - const struct config_enum_entry * options, + const struct config_enum_entry *options, GucContext context, int flags, GucEnumCheckHook check_hook, @@ -447,4 +447,4 @@ extern bool check_wal_buffers(int *newval, void **extra, GucSource source); extern void assign_xlog_sync_method(int new_sync_method, void *extra); extern const char *quote_guc_value(const char *value, int flags); -#endif /* GUC_H */ +#endif /* GUC_H */ diff --git a/src/include/utils/guc_tables.h b/src/include/utils/guc_tables.h index 1057e55f76..20e4479252 100644 --- a/src/include/utils/guc_tables.h +++ b/src/include/utils/guc_tables.h @@ -172,7 +172,7 @@ struct config_generic }; /* bit values in status field */ -#define GUC_IS_IN_FILE 0x0001 /* found it in config file */ +#define GUC_IS_IN_FILE 0x0001 /* found it in config file */ /* * Caution: the GUC_IS_IN_FILE bit is transient state for ProcessConfigFile. * Do not assume that its value represents useful information elsewhere. @@ -269,8 +269,8 @@ extern struct config_generic **get_guc_variables(void); extern void build_guc_variables(void); /* search in enum options */ -extern const char *config_enum_lookup_by_value(struct config_enum * record, int val); -extern bool config_enum_lookup_by_name(struct config_enum * record, +extern const char *config_enum_lookup_by_value(struct config_enum *record, int val); +extern bool config_enum_lookup_by_name(struct config_enum *record, const char *value, int *retval); -#endif /* GUC_TABLES_H */ +#endif /* GUC_TABLES_H */ diff --git a/src/include/utils/hsearch.h b/src/include/utils/hsearch.h index 7964087161..bc5873ed20 100644 --- a/src/include/utils/hsearch.h +++ b/src/include/utils/hsearch.h @@ -27,7 +27,7 @@ typedef uint32 (*HashValueFunc) (const void *key, Size keysize); * as key comparison functions.) */ typedef int (*HashCompareFunc) (const void *key1, const void *key2, - Size keysize); + Size keysize); /* * Key copying functions must have this signature. The return value is not @@ -157,4 +157,4 @@ extern int bitmap_match(const void *key1, const void *key2, Size keysize); #define oid_hash uint32_hash /* Remove me eventually */ -#endif /* HSEARCH_H */ +#endif /* HSEARCH_H */ diff --git a/src/include/utils/index_selfuncs.h b/src/include/utils/index_selfuncs.h index 17d165ca65..24f2f3a866 100644 --- a/src/include/utils/index_selfuncs.h +++ b/src/include/utils/index_selfuncs.h @@ -71,4 +71,4 @@ extern void gincostestimate(struct PlannerInfo *root, double *indexCorrelation, double *indexPages); -#endif /* INDEX_SELFUNCS_H */ +#endif /* INDEX_SELFUNCS_H */ diff --git a/src/include/utils/inet.h b/src/include/utils/inet.h index 7dc179e255..f2aa864a35 100644 --- a/src/include/utils/inet.h +++ b/src/include/utils/inet.h @@ -146,4 +146,4 @@ extern inet *cidr_set_masklen_internal(const inet *src, int bits); extern int bitncmp(const unsigned char *l, const unsigned char *r, int n); extern int bitncommon(const unsigned char *l, const unsigned char *r, int n); -#endif /* INET_H */ +#endif /* INET_H */ diff --git a/src/include/utils/int8.h b/src/include/utils/int8.h index c58ee048cf..8b78983fee 100644 --- a/src/include/utils/int8.h +++ b/src/include/utils/int8.h @@ -22,4 +22,4 @@ extern bool scanint8(const char *str, bool errorOK, int64 *result); -#endif /* INT8_H */ +#endif /* INT8_H */ diff --git a/src/include/utils/inval.h b/src/include/utils/inval.h index afbe354b4d..361543f412 100644 --- a/src/include/utils/inval.h +++ b/src/include/utils/inval.h @@ -63,4 +63,4 @@ extern void CacheRegisterRelcacheCallback(RelcacheCallbackFunction func, extern void CallSyscacheCallbacks(int cacheid, uint32 hashvalue); extern void InvalidateSystemCaches(void); -#endif /* INVAL_H */ +#endif /* INVAL_H */ diff --git a/src/include/utils/json.h b/src/include/utils/json.h index 0a749b90c8..e3ffe6fc44 100644 --- a/src/include/utils/json.h +++ b/src/include/utils/json.h @@ -19,4 +19,4 @@ /* functions in json.c */ extern void escape_json(StringInfo buf, const char *str); -#endif /* JSON_H */ +#endif /* JSON_H */ diff --git a/src/include/utils/jsonapi.h b/src/include/utils/jsonapi.h index 44ee36931e..4336823de2 100644 --- a/src/include/utils/jsonapi.h +++ b/src/include/utils/jsonapi.h @@ -143,8 +143,8 @@ extern void iterate_jsonb_string_values(Jsonb *jb, void *state, extern void iterate_json_string_values(text *json, void *action_state, JsonIterateStringValuesAction action); extern Jsonb *transform_jsonb_string_values(Jsonb *jsonb, void *action_state, - JsonTransformStringValuesAction transform_action); + JsonTransformStringValuesAction transform_action); extern text *transform_json_string_values(text *json, void *action_state, - JsonTransformStringValuesAction transform_action); + JsonTransformStringValuesAction transform_action); -#endif /* JSONAPI_H */ +#endif /* JSONAPI_H */ diff --git a/src/include/utils/jsonb.h b/src/include/utils/jsonb.h index 411e158d6c..ea9dd17540 100644 --- a/src/include/utils/jsonb.h +++ b/src/include/utils/jsonb.h @@ -148,7 +148,7 @@ typedef uint32 JEntry; #define JENTRY_ISBOOL_FALSE 0x20000000 #define JENTRY_ISBOOL_TRUE 0x30000000 #define JENTRY_ISNULL 0x40000000 -#define JENTRY_ISCONTAINER 0x50000000 /* array or object */ +#define JENTRY_ISCONTAINER 0x50000000 /* array or object */ /* Access macros. Note possible multiple evaluations */ #define JBE_OFFLENFLD(je_) ((je_) & JENTRY_OFFLENMASK) @@ -200,8 +200,8 @@ typedef struct JsonbContainer } JsonbContainer; /* flags for the header-field in JsonbContainer */ -#define JB_CMASK 0x0FFFFFFF /* mask for count field */ -#define JB_FSCALAR 0x10000000 /* flag bits */ +#define JB_CMASK 0x0FFFFFFF /* mask for count field */ +#define JB_FSCALAR 0x10000000 /* flag bits */ #define JB_FOBJECT 0x20000000 #define JB_FARRAY 0x40000000 @@ -263,7 +263,7 @@ struct JsonbValue { int nElems; JsonbValue *elems; - bool rawScalar; /* Top-level "raw scalar" array? */ + bool rawScalar; /* Top-level "raw scalar" array? */ } array; /* Array container type */ struct @@ -378,4 +378,4 @@ extern char *JsonbToCStringIndent(StringInfo out, JsonbContainer *in, int estimated_len); -#endif /* __JSONB_H__ */ +#endif /* __JSONB_H__ */ diff --git a/src/include/utils/logtape.h b/src/include/utils/logtape.h index e802c4b213..a1e869b80c 100644 --- a/src/include/utils/logtape.h +++ b/src/include/utils/logtape.h @@ -43,4 +43,4 @@ extern void LogicalTapeTell(LogicalTapeSet *lts, int tapenum, long *blocknum, int *offset); extern long LogicalTapeSetBlocks(LogicalTapeSet *lts); -#endif /* LOGTAPE_H */ +#endif /* LOGTAPE_H */ diff --git a/src/include/utils/lsyscache.h b/src/include/utils/lsyscache.h index 8da59bbf3e..32121311a8 100644 --- a/src/include/utils/lsyscache.h +++ b/src/include/utils/lsyscache.h @@ -220,4 +220,4 @@ extern Oid get_tablesample_method_id(const char *methodname); #define TypeIsToastable(typid) (get_typstorage(typid) != 'p') -#endif /* LSYSCACHE_H */ +#endif /* LSYSCACHE_H */ diff --git a/src/include/utils/memdebug.h b/src/include/utils/memdebug.h index 206e6ce002..a73d505be8 100644 --- a/src/include/utils/memdebug.h +++ b/src/include/utils/memdebug.h @@ -43,7 +43,7 @@ wipe_mem(void *ptr, size_t size) VALGRIND_MAKE_MEM_NOACCESS(ptr, size); } -#endif /* CLOBBER_FREED_MEMORY */ +#endif /* CLOBBER_FREED_MEMORY */ #ifdef MEMORY_CONTEXT_CHECKING @@ -70,13 +70,13 @@ sentinel_ok(const void *base, Size offset) return ret; } -#endif /* MEMORY_CONTEXT_CHECKING */ +#endif /* MEMORY_CONTEXT_CHECKING */ #ifdef RANDOMIZE_ALLOCATED_MEMORY void randomize_mem(char *ptr, size_t size); -#endif /* RANDOMIZE_ALLOCATED_MEMORY */ +#endif /* RANDOMIZE_ALLOCATED_MEMORY */ -#endif /* MEMDEBUG_H */ +#endif /* MEMDEBUG_H */ diff --git a/src/include/utils/memutils.h b/src/include/utils/memutils.h index 58e816d8e9..c553349066 100644 --- a/src/include/utils/memutils.h +++ b/src/include/utils/memutils.h @@ -37,7 +37,7 @@ * MemoryContextAllocHuge(). Both limits permit code to assume that it may * compute twice an allocation's size without overflow. */ -#define MaxAllocSize ((Size) 0x3fffffff) /* 1 gigabyte - 1 */ +#define MaxAllocSize ((Size) 0x3fffffff) /* 1 gigabyte - 1 */ #define AllocSizeIsValid(size) ((Size) (size) <= MaxAllocSize) @@ -194,4 +194,4 @@ extern MemoryContext SlabContextCreate(MemoryContext parent, #define SLAB_DEFAULT_BLOCK_SIZE (8 * 1024) #define SLAB_LARGE_BLOCK_SIZE (8 * 1024 * 1024) -#endif /* MEMUTILS_H */ +#endif /* MEMUTILS_H */ diff --git a/src/include/utils/nabstime.h b/src/include/utils/nabstime.h index 4b0706a316..69133952d1 100644 --- a/src/include/utils/nabstime.h +++ b/src/include/utils/nabstime.h @@ -73,11 +73,11 @@ typedef TimeIntervalData *TimeInterval; * These were chosen as special 32-bit bit patterns, * so redefine them explicitly using these bit patterns. - tgl 97/02/24 */ -#define INVALID_ABSTIME ((AbsoluteTime) 0x7FFFFFFE) /* 2147483647 (2^31 - 1) */ -#define NOEND_ABSTIME ((AbsoluteTime) 0x7FFFFFFC) /* 2147483645 (2^31 - 3) */ -#define NOSTART_ABSTIME ((AbsoluteTime) INT_MIN) /* -2147483648 */ +#define INVALID_ABSTIME ((AbsoluteTime) 0x7FFFFFFE) /* 2147483647 (2^31 - 1) */ +#define NOEND_ABSTIME ((AbsoluteTime) 0x7FFFFFFC) /* 2147483645 (2^31 - 3) */ +#define NOSTART_ABSTIME ((AbsoluteTime) INT_MIN) /* -2147483648 */ -#define INVALID_RELTIME ((RelativeTime) 0x7FFFFFFE) /* 2147483647 (2^31 - 1) */ +#define INVALID_RELTIME ((RelativeTime) 0x7FFFFFFE) /* 2147483647 (2^31 - 1) */ #define AbsoluteTimeIsValid(time) \ ((bool) ((time) != INVALID_ABSTIME)) @@ -98,6 +98,6 @@ typedef TimeIntervalData *TimeInterval; /* non-fmgr-callable support routines */ extern AbsoluteTime GetCurrentAbsoluteTime(void); -extern void abstime2tm(AbsoluteTime time, int *tzp, struct pg_tm * tm, char **tzn); +extern void abstime2tm(AbsoluteTime time, int *tzp, struct pg_tm *tm, char **tzn); -#endif /* NABSTIME_H */ +#endif /* NABSTIME_H */ diff --git a/src/include/utils/numeric.h b/src/include/utils/numeric.h index 0ab57d7025..3aa7fef947 100644 --- a/src/include/utils/numeric.h +++ b/src/include/utils/numeric.h @@ -61,4 +61,4 @@ int32 numeric_maximum_size(int32 typmod); extern char *numeric_out_sci(Numeric num, int scale); extern char *numeric_normalize(Numeric num); -#endif /* _PG_NUMERIC_H_ */ +#endif /* _PG_NUMERIC_H_ */ diff --git a/src/include/utils/palloc.h b/src/include/utils/palloc.h index 2e07bd57ad..a7dc837724 100644 --- a/src/include/utils/palloc.h +++ b/src/include/utils/palloc.h @@ -113,7 +113,7 @@ MemoryContextSwitchTo(MemoryContext context) CurrentMemoryContext = context; return old; } -#endif /* FRONTEND */ +#endif /* FRONTEND */ /* Registration of memory context reset/delete callbacks */ extern void MemoryContextRegisterResetCallback(MemoryContext context, @@ -133,4 +133,4 @@ extern char *pchomp(const char *in); extern char *psprintf(const char *fmt,...) pg_attribute_printf(1, 2); extern size_t pvsnprintf(char *buf, size_t len, const char *fmt, va_list args) pg_attribute_printf(3, 0); -#endif /* PALLOC_H */ +#endif /* PALLOC_H */ diff --git a/src/include/utils/pg_crc.h b/src/include/utils/pg_crc.h index 2fe083850a..9ea0622321 100644 --- a/src/include/utils/pg_crc.h +++ b/src/include/utils/pg_crc.h @@ -104,4 +104,4 @@ do { \ */ extern PGDLLIMPORT const uint32 pg_crc32_table[256]; -#endif /* PG_CRC_H */ +#endif /* PG_CRC_H */ diff --git a/src/include/utils/pg_locale.h b/src/include/utils/pg_locale.h index f0acc86b88..a02d27ba26 100644 --- a/src/include/utils/pg_locale.h +++ b/src/include/utils/pg_locale.h @@ -93,7 +93,7 @@ extern char *get_collation_actual_version(char collprovider, const char *collcol #ifdef USE_ICU extern int32_t icu_to_uchar(UChar **buff_uchar, const char *buff, size_t nbytes); -extern int32_t icu_from_uchar(char **result, UChar *buff_uchar, int32_t len_uchar); +extern int32_t icu_from_uchar(char **result, const UChar *buff_uchar, int32_t len_uchar); #endif /* These functions convert from/to libc's wchar_t, *not* pg_wchar_t */ @@ -104,4 +104,4 @@ extern size_t char2wchar(wchar_t *to, size_t tolen, const char *from, size_t fromlen, pg_locale_t locale); #endif -#endif /* _PG_LOCALE_ */ +#endif /* _PG_LOCALE_ */ diff --git a/src/include/utils/pg_lsn.h b/src/include/utils/pg_lsn.h index 6f038e9e14..cc51b2a078 100644 --- a/src/include/utils/pg_lsn.h +++ b/src/include/utils/pg_lsn.h @@ -24,4 +24,4 @@ #define PG_GETARG_LSN(n) DatumGetLSN(PG_GETARG_DATUM(n)) #define PG_RETURN_LSN(x) return LSNGetDatum(x) -#endif /* PG_LSN_H */ +#endif /* PG_LSN_H */ diff --git a/src/include/utils/pg_rusage.h b/src/include/utils/pg_rusage.h index 48a74e90ba..cea51f0cb2 100644 --- a/src/include/utils/pg_rusage.h +++ b/src/include/utils/pg_rusage.h @@ -34,4 +34,4 @@ typedef struct PGRUsage extern void pg_rusage_init(PGRUsage *ru0); extern const char *pg_rusage_show(const PGRUsage *ru0); -#endif /* PG_RUSAGE_H */ +#endif /* PG_RUSAGE_H */ diff --git a/src/include/utils/plancache.h b/src/include/utils/plancache.h index fbb271ed1c..2cb2241f45 100644 --- a/src/include/utils/plancache.h +++ b/src/include/utils/plancache.h @@ -81,7 +81,7 @@ struct RawStmt; typedef struct CachedPlanSource { int magic; /* should equal CACHEDPLANSOURCE_MAGIC */ - struct RawStmt *raw_parse_tree; /* output of raw_parser(), or NULL */ + struct RawStmt *raw_parse_tree; /* output of raw_parser(), or NULL */ const char *query_string; /* source text of query */ const char *commandTag; /* command tag (a constant!), or NULL */ Oid *param_types; /* array of parameter type OIDs, or NULL */ @@ -96,11 +96,11 @@ typedef struct CachedPlanSource List *query_list; /* list of Query nodes, or NIL if not valid */ List *relationOids; /* OIDs of relations the queries depend on */ List *invalItems; /* other dependencies, as PlanInvalItems */ - struct OverrideSearchPath *search_path; /* search_path used for - * parsing and planning */ + struct OverrideSearchPath *search_path; /* search_path used for parsing + * and planning */ MemoryContext query_context; /* context holding the above, or NULL */ Oid rewriteRoleId; /* Role ID we did rewriting for */ - bool rewriteRowSecurity; /* row_security used during rewrite */ + bool rewriteRowSecurity; /* row_security used during rewrite */ bool dependsOnRLS; /* is rewritten query specific to the above? */ /* If we have a generic plan, this is a reference-counted link to it: */ struct CachedPlan *gplan; /* generic plan, or NULL if not valid */ @@ -111,11 +111,11 @@ typedef struct CachedPlanSource bool is_valid; /* is the query_list currently valid? */ int generation; /* increments each time we create a plan */ /* If CachedPlanSource has been saved, it is a member of a global list */ - struct CachedPlanSource *next_saved; /* list link, if so */ + struct CachedPlanSource *next_saved; /* list link, if so */ /* State kept to help decide whether to use custom or generic plans: */ double generic_cost; /* cost of generic plan, or -1 if not known */ - double total_custom_cost; /* total cost of custom plans so far */ - int num_custom_plans; /* number of plans included in total */ + double total_custom_cost; /* total cost of custom plans so far */ + int num_custom_plans; /* number of plans included in total */ #ifdef PGXC char *stmt_name; /* If set, this is a copy of prepared stmt name */ #endif @@ -193,4 +193,4 @@ extern void SetRemoteSubplan(CachedPlanSource *plansource, const char *plan_string); #endif -#endif /* PLANCACHE_H */ +#endif /* PLANCACHE_H */ diff --git a/src/include/utils/portal.h b/src/include/utils/portal.h index c9ce886483..0ec2eba5d3 100644 --- a/src/include/utils/portal.h +++ b/src/include/utils/portal.h @@ -123,7 +123,7 @@ typedef struct PortalData const char *prepStmtName; /* source prepared statement (NULL if none) */ MemoryContext heap; /* subsidiary memory for portal */ ResourceOwner resowner; /* resources owned by portal */ - void (*cleanup) (Portal portal); /* cleanup hook */ + void (*cleanup) (Portal portal); /* cleanup hook */ /* * State data for remembering which subtransaction(s) the portal was @@ -132,8 +132,8 @@ typedef struct PortalData * createSubid is the creating subxact and activeSubid is the last subxact * in which we ran the portal. */ - SubTransactionId createSubid; /* the creating subxact */ - SubTransactionId activeSubid; /* the last subxact with activity */ + SubTransactionId createSubid; /* the creating subxact */ + SubTransactionId activeSubid; /* the last subxact with activity */ /* The query or queries the portal will execute */ const char *sourceText; /* text of query (as of 8.4, never NULL) */ @@ -198,7 +198,7 @@ typedef struct PortalData /* Presentation data, primarily used by the pg_cursors system view */ TimestampTz creation_time; /* time at which this portal was defined */ bool visible; /* include this portal in pg_cursors? */ -} PortalData; +} PortalData; /* * PortalIsValid @@ -253,4 +253,4 @@ extern bool portalIsProducing(Portal portal); #endif extern bool ThereAreNoReadyPortals(void); -#endif /* PORTAL_H */ +#endif /* PORTAL_H */ diff --git a/src/include/utils/ps_status.h b/src/include/utils/ps_status.h index 3f503cc187..2ba5a0ea2e 100644 --- a/src/include/utils/ps_status.h +++ b/src/include/utils/ps_status.h @@ -23,4 +23,4 @@ extern void set_ps_display(const char *activity, bool force); extern const char *get_ps_display(int *displen); -#endif /* PS_STATUS_H */ +#endif /* PS_STATUS_H */ diff --git a/src/include/utils/queryenvironment.h b/src/include/utils/queryenvironment.h index 291b6fdbc2..08e6051b4e 100644 --- a/src/include/utils/queryenvironment.h +++ b/src/include/utils/queryenvironment.h @@ -71,4 +71,4 @@ extern void unregister_ENR(QueryEnvironment *queryEnv, const char *name); extern EphemeralNamedRelation get_ENR(QueryEnvironment *queryEnv, const char *name); extern TupleDesc ENRMetadataGetTupDesc(EphemeralNamedRelationMetadata enrmd); -#endif /* QUERYENVIRONMENT_H */ +#endif /* QUERYENVIRONMENT_H */ diff --git a/src/include/utils/rangetypes.h b/src/include/utils/rangetypes.h index abb2223ec5..5544889317 100644 --- a/src/include/utils/rangetypes.h +++ b/src/include/utils/rangetypes.h @@ -40,8 +40,8 @@ typedef struct #define RANGE_UB_INF 0x10 /* upper bound is +infinity */ #define RANGE_LB_NULL 0x20 /* lower bound is null (NOT USED) */ #define RANGE_UB_NULL 0x40 /* upper bound is null (NOT USED) */ -#define RANGE_CONTAIN_EMPTY 0x80/* marks a GiST internal-page entry whose - * subtree contains some empty ranges */ +#define RANGE_CONTAIN_EMPTY 0x80 /* marks a GiST internal-page entry whose + * subtree contains some empty ranges */ #define RANGE_HAS_LBOUND(flags) (!((flags) & (RANGE_EMPTY | \ RANGE_LB_NULL | \ @@ -136,4 +136,4 @@ extern bool bounds_adjacent(TypeCacheEntry *typcache, RangeBound bound1, RangeBound bound2); extern RangeType *make_empty_range(TypeCacheEntry *typcache); -#endif /* RANGETYPES_H */ +#endif /* RANGETYPES_H */ diff --git a/src/include/utils/rel.h b/src/include/utils/rel.h index dd5de58fef..ab07f614c8 100644 --- a/src/include/utils/rel.h +++ b/src/include/utils/rel.h @@ -74,7 +74,7 @@ typedef struct PartitionKeyData bool *parttypbyval; char *parttypalign; Oid *parttypcoll; -} PartitionKeyData; +} PartitionKeyData; typedef struct PartitionKeyData *PartitionKey; @@ -128,9 +128,9 @@ typedef struct RelationData bool rd_fkeyvalid; /* true if list has been computed */ MemoryContext rd_partkeycxt; /* private memory cxt for the below */ - struct PartitionKeyData *rd_partkey; /* partition key, or NULL */ + struct PartitionKeyData *rd_partkey; /* partition key, or NULL */ MemoryContext rd_pdcxt; /* private context for partdesc */ - struct PartitionDescData *rd_partdesc; /* partitions, or NULL */ + struct PartitionDescData *rd_partdesc; /* partitions, or NULL */ List *rd_partcheck; /* partition CHECK quals */ /* data managed by RelationGetIndexList: */ @@ -160,7 +160,7 @@ typedef struct RelationData /* These are non-NULL only for an index relation: */ Form_pg_index rd_index; /* pg_index tuple describing this index */ /* use "struct" here to avoid needing to include htup.h: */ - struct HeapTupleData *rd_indextuple; /* all of pg_index tuple */ + struct HeapTupleData *rd_indextuple; /* all of pg_index tuple */ /* * index access support info (used only for an index relation) @@ -180,7 +180,7 @@ typedef struct RelationData Oid rd_amhandler; /* OID of index AM's handler function */ MemoryContext rd_indexcxt; /* private memory cxt for this stuff */ /* use "struct" here to avoid needing to include amapi.h: */ - struct IndexAmRoutine *rd_amroutine; /* index AM's API struct */ + struct IndexAmRoutine *rd_amroutine; /* index AM's API struct */ Oid *rd_opfamily; /* OIDs of op families for each index col */ Oid *rd_opcintype; /* OIDs of opclass declared input data types */ RegProcedure *rd_support; /* OIDs of support procedures */ @@ -217,7 +217,7 @@ typedef struct RelationData Oid rd_toastoid; /* Real TOAST table's OID, or InvalidOid */ /* use "struct" here to avoid needing to include pgstat.h: */ - struct PgStat_TableStatus *pgstat_info; /* statistics collection area */ + struct PgStat_TableStatus *pgstat_info; /* statistics collection area */ #ifdef PGXC RelationLocInfo *rd_locator_info; #endif @@ -246,8 +246,8 @@ typedef struct ForeignKeyCacheInfo int nkeys; /* number of columns in the foreign key */ /* these arrays each have nkeys valid entries: */ AttrNumber conkey[INDEX_MAX_KEYS]; /* cols in referencing table */ - AttrNumber confkey[INDEX_MAX_KEYS]; /* cols in referenced table */ - Oid conpfeqop[INDEX_MAX_KEYS]; /* PK = FK operator OIDs */ + AttrNumber confkey[INDEX_MAX_KEYS]; /* cols in referenced table */ + Oid conpfeqop[INDEX_MAX_KEYS]; /* PK = FK operator OIDs */ } ForeignKeyCacheInfo; @@ -283,9 +283,8 @@ typedef struct StdRdOptions int32 vl_len_; /* varlena header (do not touch directly!) */ int fillfactor; /* page fill factor in percent (0..100) */ AutoVacOpts autovacuum; /* autovacuum-related options */ - bool user_catalog_table; /* use as an additional catalog - * relation */ - int parallel_workers; /* max number of parallel workers */ + bool user_catalog_table; /* use as an additional catalog relation */ + int parallel_workers; /* max number of parallel workers */ } StdRdOptions; #define HEAP_MIN_FILLFACTOR 10 @@ -691,4 +690,4 @@ extern void RelationDecrementReferenceCount(Relation rel); extern bool RelationHasUnloggedIndex(Relation rel); extern List *RelationGetRepsetList(Relation rel); -#endif /* REL_H */ +#endif /* REL_H */ diff --git a/src/include/utils/relcache.h b/src/include/utils/relcache.h index 81af3aebb8..3c53cefe4b 100644 --- a/src/include/utils/relcache.h +++ b/src/include/utils/relcache.h @@ -135,4 +135,4 @@ extern bool criticalRelcachesBuilt; /* should be used only by relcache.c and postinit.c */ extern bool criticalSharedRelcachesBuilt; -#endif /* RELCACHE_H */ +#endif /* RELCACHE_H */ diff --git a/src/include/utils/relfilenodemap.h b/src/include/utils/relfilenodemap.h index 0827ff3db8..b3ee555fb7 100644 --- a/src/include/utils/relfilenodemap.h +++ b/src/include/utils/relfilenodemap.h @@ -15,4 +15,4 @@ extern Oid RelidByRelfilenode(Oid reltablespace, Oid relfilenode); -#endif /* RELFILENODEMAP_H */ +#endif /* RELFILENODEMAP_H */ diff --git a/src/include/utils/relmapper.h b/src/include/utils/relmapper.h index 8fb2879ff9..7af69ba6cf 100644 --- a/src/include/utils/relmapper.h +++ b/src/include/utils/relmapper.h @@ -63,4 +63,4 @@ extern void relmap_redo(XLogReaderState *record); extern void relmap_desc(StringInfo buf, XLogReaderState *record); extern const char *relmap_identify(uint8 info); -#endif /* RELMAPPER_H */ +#endif /* RELMAPPER_H */ diff --git a/src/include/utils/relptr.h b/src/include/utils/relptr.h index 1e5e622150..06e592e0c6 100644 --- a/src/include/utils/relptr.h +++ b/src/include/utils/relptr.h @@ -74,4 +74,4 @@ #define relptr_copy(rp1, rp2) \ ((rp1).relptr_off = (rp2).relptr_off) -#endif /* RELPTR_H */ +#endif /* RELPTR_H */ diff --git a/src/include/utils/reltrigger.h b/src/include/utils/reltrigger.h index 65d6ecb30a..2169b0306b 100644 --- a/src/include/utils/reltrigger.h +++ b/src/include/utils/reltrigger.h @@ -77,4 +77,4 @@ typedef struct TriggerDesc bool trig_delete_old_table; } TriggerDesc; -#endif /* RELTRIGGER_H */ +#endif /* RELTRIGGER_H */ diff --git a/src/include/utils/resowner.h b/src/include/utils/resowner.h index ff785e3a3e..07d30d93bc 100644 --- a/src/include/utils/resowner.h +++ b/src/include/utils/resowner.h @@ -54,9 +54,9 @@ typedef enum * by providing a callback of this form. */ typedef void (*ResourceReleaseCallback) (ResourceReleasePhase phase, - bool isCommit, - bool isTopLevel, - void *arg); + bool isCommit, + bool isTopLevel, + void *arg); /* @@ -79,4 +79,4 @@ extern void RegisterResourceReleaseCallback(ResourceReleaseCallback callback, extern void UnregisterResourceReleaseCallback(ResourceReleaseCallback callback, void *arg); -#endif /* RESOWNER_H */ +#endif /* RESOWNER_H */ diff --git a/src/include/utils/resowner_private.h b/src/include/utils/resowner_private.h index 2f763d7539..4c9d1fe50e 100644 --- a/src/include/utils/resowner_private.h +++ b/src/include/utils/resowner_private.h @@ -97,4 +97,4 @@ extern void ResourceOwnerForgetPreparedStmt(ResourceOwner owner, char *stmt); #endif -#endif /* RESOWNER_PRIVATE_H */ +#endif /* RESOWNER_PRIVATE_H */ diff --git a/src/include/utils/rls.h b/src/include/utils/rls.h index fa2c44e160..f9780ad0c0 100644 --- a/src/include/utils/rls.h +++ b/src/include/utils/rls.h @@ -47,4 +47,4 @@ enum CheckEnableRlsResult extern int check_enable_rls(Oid relid, Oid checkAsUser, bool noError); -#endif /* RLS_H */ +#endif /* RLS_H */ diff --git a/src/include/utils/ruleutils.h b/src/include/utils/ruleutils.h index 42fc872c4a..a2206cb7cd 100644 --- a/src/include/utils/ruleutils.h +++ b/src/include/utils/ruleutils.h @@ -34,4 +34,4 @@ extern List *select_rtable_names_for_explain(List *rtable, Bitmapset *rels_used); extern char *generate_collation_name(Oid collid); -#endif /* RULEUTILS_H */ +#endif /* RULEUTILS_H */ diff --git a/src/include/utils/sampling.h b/src/include/utils/sampling.h index 7edfc4a44d..f566e0b866 100644 --- a/src/include/utils/sampling.h +++ b/src/include/utils/sampling.h @@ -32,7 +32,7 @@ typedef struct int n; /* desired sample size */ BlockNumber t; /* current block number */ int m; /* blocks selected so far */ - SamplerRandomState randstate; /* random generator state */ + SamplerRandomState randstate; /* random generator state */ } BlockSamplerData; typedef BlockSamplerData *BlockSampler; @@ -47,7 +47,7 @@ extern BlockNumber BlockSampler_Next(BlockSampler bs); typedef struct { double W; - SamplerRandomState randstate; /* random generator state */ + SamplerRandomState randstate; /* random generator state */ } ReservoirStateData; typedef ReservoirStateData *ReservoirState; @@ -62,4 +62,4 @@ extern double anl_random_fract(void); extern double anl_init_selection_state(int n); extern double anl_get_next_S(double t, int n, double *stateptr); -#endif /* SAMPLING_H */ +#endif /* SAMPLING_H */ diff --git a/src/include/utils/selfuncs.h b/src/include/utils/selfuncs.h index 958bdba455..c7fdd540e8 100644 --- a/src/include/utils/selfuncs.h +++ b/src/include/utils/selfuncs.h @@ -126,10 +126,10 @@ typedef struct typedef struct { /* These are the values the cost estimator must return to the planner */ - Cost indexStartupCost; /* index-related startup cost */ + Cost indexStartupCost; /* index-related startup cost */ Cost indexTotalCost; /* total index-related scan cost */ - Selectivity indexSelectivity; /* selectivity of index */ - double indexCorrelation; /* order correlation of index */ + Selectivity indexSelectivity; /* selectivity of index */ + double indexCorrelation; /* order correlation of index */ /* Intermediate values we obtain along the way */ double numIndexPages; /* number of leaf pages visited */ @@ -140,14 +140,14 @@ typedef struct /* Hooks for plugins to get control when we ask for stats */ typedef bool (*get_relation_stats_hook_type) (PlannerInfo *root, - RangeTblEntry *rte, - AttrNumber attnum, - VariableStatData *vardata); + RangeTblEntry *rte, + AttrNumber attnum, + VariableStatData *vardata); extern PGDLLIMPORT get_relation_stats_hook_type get_relation_stats_hook; typedef bool (*get_index_stats_hook_type) (PlannerInfo *root, - Oid indexOid, - AttrNumber indexattnum, - VariableStatData *vardata); + Oid indexOid, + AttrNumber indexattnum, + VariableStatData *vardata); extern PGDLLIMPORT get_index_stats_hook_type get_index_stats_hook; /* Functions in selfuncs.c */ @@ -222,4 +222,4 @@ extern Selectivity scalararraysel_containment(PlannerInfo *root, Oid elemtype, bool isEquality, bool useOr, int varRelid); -#endif /* SELFUNCS_H */ +#endif /* SELFUNCS_H */ diff --git a/src/include/utils/snapmgr.h b/src/include/utils/snapmgr.h index 2a3f8eca34..fc64153780 100644 --- a/src/include/utils/snapmgr.h +++ b/src/include/utils/snapmgr.h @@ -110,4 +110,4 @@ extern void SerializeSnapshot(Snapshot snapshot, char *start_address); extern Snapshot RestoreSnapshot(char *start_address); extern void RestoreTransactionSnapshot(Snapshot snapshot, void *master_pgproc); -#endif /* SNAPMGR_H */ +#endif /* SNAPMGR_H */ diff --git a/src/include/utils/snapshot.h b/src/include/utils/snapshot.h index a981d90616..b113fc9b6a 100644 --- a/src/include/utils/snapshot.h +++ b/src/include/utils/snapshot.h @@ -32,7 +32,7 @@ typedef struct SnapshotData *Snapshot; * function. */ typedef bool (*SnapshotSatisfiesFunc) (HeapTuple htup, - Snapshot snapshot, Buffer buffer); + Snapshot snapshot, Buffer buffer); /* * Struct representing all kind of possible snapshots. @@ -130,4 +130,4 @@ typedef enum HeapTupleWouldBlock /* can be returned by heap_tuple_lock */ } HTSU_Result; -#endif /* SNAPSHOT_H */ +#endif /* SNAPSHOT_H */ diff --git a/src/include/utils/sortsupport.h b/src/include/utils/sortsupport.h index 9ca8fe86ae..6e8444b4ff 100644 --- a/src/include/utils/sortsupport.h +++ b/src/include/utils/sortsupport.h @@ -72,7 +72,7 @@ typedef struct SortSupportData * sort support functions. */ bool ssup_reverse; /* descending-order sort? */ - bool ssup_nulls_first; /* sort nulls first? */ + bool ssup_nulls_first; /* sort nulls first? */ /* * These fields are workspace for callers, and should not be touched by @@ -274,4 +274,4 @@ extern void PrepareSortSupportFromOrderingOp(Oid orderingOp, SortSupport ssup); extern void PrepareSortSupportFromIndexRel(Relation indexRel, int16 strategy, SortSupport ssup); -#endif /* SORTSUPPORT_H */ +#endif /* SORTSUPPORT_H */ diff --git a/src/include/utils/spccache.h b/src/include/utils/spccache.h index 26f88da0b2..7c45bb11eb 100644 --- a/src/include/utils/spccache.h +++ b/src/include/utils/spccache.h @@ -17,4 +17,4 @@ void get_tablespace_page_costs(Oid spcid, float8 *spc_random_page_cost, float8 *spc_seq_page_cost); int get_tablespace_io_concurrency(Oid spcid); -#endif /* SPCCACHE_H */ +#endif /* SPCCACHE_H */ diff --git a/src/include/utils/syscache.h b/src/include/utils/syscache.h index 67cc6f4c23..211e47bc40 100644 --- a/src/include/utils/syscache.h +++ b/src/include/utils/syscache.h @@ -218,4 +218,4 @@ extern bool RelationSupportsSysCache(Oid relid); #define ReleaseSysCacheList(x) ReleaseCatCacheList(x) -#endif /* SYSCACHE_H */ +#endif /* SYSCACHE_H */ diff --git a/src/include/utils/timeout.h b/src/include/utils/timeout.h index aa816334c0..5a2efc0dd9 100644 --- a/src/include/utils/timeout.h +++ b/src/include/utils/timeout.h @@ -84,4 +84,4 @@ extern bool get_timeout_indicator(TimeoutId id, bool reset_indicator); extern TimestampTz get_timeout_start_time(TimeoutId id); extern TimestampTz get_timeout_finish_time(TimeoutId id); -#endif /* TIMEOUT_H */ +#endif /* TIMEOUT_H */ diff --git a/src/include/utils/timestamp.h b/src/include/utils/timestamp.h index 5e7e353b73..f778037e05 100644 --- a/src/include/utils/timestamp.h +++ b/src/include/utils/timestamp.h @@ -84,16 +84,16 @@ extern pg_time_t timestamptz_to_time_t(TimestampTz t); extern const char *timestamptz_to_str(TimestampTz t); -extern int tm2timestamp(struct pg_tm * tm, fsec_t fsec, int *tzp, Timestamp *dt); -extern int timestamp2tm(Timestamp dt, int *tzp, struct pg_tm * tm, +extern int tm2timestamp(struct pg_tm *tm, fsec_t fsec, int *tzp, Timestamp *dt); +extern int timestamp2tm(Timestamp dt, int *tzp, struct pg_tm *tm, fsec_t *fsec, const char **tzn, pg_tz *attimezone); extern void dt2time(Timestamp dt, int *hour, int *min, int *sec, fsec_t *fsec); -extern int interval2tm(Interval span, struct pg_tm * tm, fsec_t *fsec); -extern int tm2interval(struct pg_tm * tm, fsec_t fsec, Interval *span); +extern int interval2tm(Interval span, struct pg_tm *tm, fsec_t *fsec); +extern int tm2interval(struct pg_tm *tm, fsec_t fsec, Interval *span); extern Timestamp SetEpochTimestamp(void); -extern void GetEpochTime(struct pg_tm * tm); +extern void GetEpochTime(struct pg_tm *tm); extern int timestamp_cmp_internal(Timestamp dt1, Timestamp dt2); @@ -107,4 +107,4 @@ extern int date2isoweek(int year, int mon, int mday); extern int date2isoyear(int year, int mon, int mday); extern int date2isoyearday(int year, int mon, int mday); -#endif /* TIMESTAMP_H */ +#endif /* TIMESTAMP_H */ diff --git a/src/include/utils/tqual.h b/src/include/utils/tqual.h index f39f21bb64..036d9898d6 100644 --- a/src/include/utils/tqual.h +++ b/src/include/utils/tqual.h @@ -51,7 +51,7 @@ typedef enum HEAPTUPLE_DEAD, /* tuple is dead and deletable */ HEAPTUPLE_LIVE, /* tuple is live (committed, no deleter) */ HEAPTUPLE_RECENTLY_DEAD, /* tuple is dead, but not deletable yet */ - HEAPTUPLE_INSERT_IN_PROGRESS, /* inserting xact is still in progress */ + HEAPTUPLE_INSERT_IN_PROGRESS, /* inserting xact is still in progress */ HEAPTUPLE_DELETE_IN_PROGRESS /* deleting xact is still in progress */ } HTSV_Result; @@ -109,4 +109,4 @@ extern bool ResolveCminCmaxDuringDecoding(struct HTAB *tuplecid_data, (snapshotdata).lsn = (l), \ (snapshotdata).whenTaken = (w)) -#endif /* TQUAL_H */ +#endif /* TQUAL_H */ diff --git a/src/include/utils/tuplesort.h b/src/include/utils/tuplesort.h index d6be7fe826..97bb38f84e 100644 --- a/src/include/utils/tuplesort.h +++ b/src/include/utils/tuplesort.h @@ -134,4 +134,4 @@ extern void tuplesort_rescan(Tuplesortstate *state); extern void tuplesort_markpos(Tuplesortstate *state); extern void tuplesort_restorepos(Tuplesortstate *state); -#endif /* TUPLESORT_H */ +#endif /* TUPLESORT_H */ diff --git a/src/include/utils/tuplestore.h b/src/include/utils/tuplestore.h index aef4fc9840..33b5c9f996 100644 --- a/src/include/utils/tuplestore.h +++ b/src/include/utils/tuplestore.h @@ -99,4 +99,4 @@ extern char *tuplestore_getmessage(Tuplestorestate *state, int *len); extern void tuplestore_collect_stat(Tuplestorestate *state, char *name); -#endif /* TUPLESTORE_H */ +#endif /* TUPLESTORE_H */ diff --git a/src/include/utils/typcache.h b/src/include/utils/typcache.h index 1bf94e2548..c12631dafe 100644 --- a/src/include/utils/typcache.h +++ b/src/include/utils/typcache.h @@ -83,9 +83,9 @@ typedef struct TypeCacheEntry */ struct TypeCacheEntry *rngelemtype; /* range's element type */ Oid rng_collation; /* collation for comparisons, if any */ - FmgrInfo rng_cmp_proc_finfo; /* comparison function */ + FmgrInfo rng_cmp_proc_finfo; /* comparison function */ FmgrInfo rng_canonical_finfo; /* canonicalization function, if any */ - FmgrInfo rng_subdiff_finfo; /* difference function, if any */ + FmgrInfo rng_subdiff_finfo; /* difference function, if any */ /* * Domain constraint data if it's a domain type. NULL if not domain, or @@ -136,7 +136,7 @@ typedef struct DomainConstraintRef /* Management data --- treat these fields as private to typcache.c */ DomainConstraintCache *dcc; /* current constraints, or NULL if none */ - MemoryContextCallback callback; /* used to release refcount when done */ + MemoryContextCallback callback; /* used to release refcount when done */ } DomainConstraintRef; @@ -160,4 +160,4 @@ extern void assign_record_type_typmod(TupleDesc tupDesc); extern int compare_values_of_enum(TypeCacheEntry *tcache, Oid arg1, Oid arg2); -#endif /* TYPCACHE_H */ +#endif /* TYPCACHE_H */ diff --git a/src/include/utils/tzparser.h b/src/include/utils/tzparser.h index c22467de1a..1e444e1159 100644 --- a/src/include/utils/tzparser.h +++ b/src/include/utils/tzparser.h @@ -36,4 +36,4 @@ typedef struct tzEntry extern TimeZoneAbbrevTable *load_tzoffsets(const char *filename); -#endif /* TZPARSER_H */ +#endif /* TZPARSER_H */ diff --git a/src/include/utils/uuid.h b/src/include/utils/uuid.h index 9e62d81c3d..ed3ec28959 100644 --- a/src/include/utils/uuid.h +++ b/src/include/utils/uuid.h @@ -28,4 +28,4 @@ typedef struct pg_uuid_t #define DatumGetUUIDP(X) ((pg_uuid_t *) DatumGetPointer(X)) #define PG_GETARG_UUID_P(X) DatumGetUUIDP(PG_GETARG_DATUM(X)) -#endif /* UUID_H */ +#endif /* UUID_H */ diff --git a/src/include/utils/xml.h b/src/include/utils/xml.h index 195b9b3a97..e6fa0e2051 100644 --- a/src/include/utils/xml.h +++ b/src/include/utils/xml.h @@ -28,19 +28,19 @@ typedef enum XML_STANDALONE_NO, XML_STANDALONE_NO_VALUE, XML_STANDALONE_OMITTED -} XmlStandaloneType; +} XmlStandaloneType; typedef enum { XMLBINARY_BASE64, XMLBINARY_HEX -} XmlBinaryType; +} XmlBinaryType; typedef enum { PG_XML_STRICTNESS_LEGACY, /* ignore errors unless function result * indicates error condition */ - PG_XML_STRICTNESS_WELLFORMED, /* ignore non-parser messages */ + PG_XML_STRICTNESS_WELLFORMED, /* ignore non-parser messages */ PG_XML_STRICTNESS_ALL /* report all notices/warnings/errors */ } PgXmlStrictness; @@ -81,4 +81,4 @@ extern int xmloption; /* XmlOptionType, but int for guc enum */ extern const TableFuncRoutine XmlTableRoutine; -#endif /* XML_H */ +#endif /* XML_H */ diff --git a/src/include/windowapi.h b/src/include/windowapi.h index 481ebe06cf..0aa23ef2f5 100644 --- a/src/include/windowapi.h +++ b/src/include/windowapi.h @@ -61,4 +61,4 @@ extern Datum WinGetFuncArgInFrame(WindowObject winobj, int argno, extern Datum WinGetFuncArgCurrent(WindowObject winobj, int argno, bool *isnull); -#endif /* WINDOWAPI_H */ +#endif /* WINDOWAPI_H */ |
