1
0
mirror of https://github.com/postgres/postgres.git synced 2025-09-03 15:22:11 +03:00

pgindent run for release 9.3

This is the first run of the Perl-based pgindent script.  Also update
pgindent instructions.
This commit is contained in:
Bruce Momjian
2013-05-29 16:58:43 -04:00
parent 07ab261ef3
commit 9af4159fce
367 changed files with 4222 additions and 3829 deletions

View File

@@ -64,6 +64,7 @@
#define F_FOLLOW_RIGHT (1 << 3) /* page to the right has no downlink */
typedef XLogRecPtr GistNSN;
/*
* For on-disk compatibility with pre-9.3 servers, NSN is stored as two
* 32-bit fields on disk, same as LSNs.
@@ -72,7 +73,7 @@ typedef PageXLogRecPtr PageGistNSN;
typedef struct GISTPageOpaqueData
{
PageGistNSN nsn; /* this value must change on page split */
PageGistNSN nsn; /* this value must change on page split */
BlockNumber rightlink; /* next page if any */
uint16 flags; /* see bit definitions above */
uint16 gist_page_id; /* for identification of GiST indexes */
@@ -97,11 +98,11 @@ typedef GISTPageOpaqueData *GISTPageOpaque;
* the union keys for each side.
*
* If spl_ldatum_exists and spl_rdatum_exists are true, then we are performing
* a "secondary split" using a non-first index column. In this case some
* a "secondary split" using a non-first index column. In this case some
* decisions have already been made about a page split, and the set of tuples
* being passed to PickSplit is just the tuples about which we are undecided.
* spl_ldatum/spl_rdatum then contain the union keys for the tuples already
* chosen to go left or right. Ideally the PickSplit method should take those
* chosen to go left or right. Ideally the PickSplit method should take those
* keys into account while deciding what to do with the remaining tuples, ie
* it should try to "build out" from those unions so as to minimally expand
* them. If it does so, it should union the given tuples' keys into the

View File

@@ -59,15 +59,15 @@ typedef enum LockTupleMode
* replacement is really a match.
* cmax is the outdating command's CID, but only when the failure code is
* HeapTupleSelfUpdated (i.e., something in the current transaction outdated
* the tuple); otherwise cmax is zero. (We make this restriction because
* the tuple); otherwise cmax is zero. (We make this restriction because
* HeapTupleHeaderGetCmax doesn't work for tuples outdated in other
* transactions.)
*/
typedef struct HeapUpdateFailureData
{
ItemPointerData ctid;
TransactionId xmax;
CommandId cmax;
ItemPointerData ctid;
TransactionId xmax;
CommandId cmax;
} HeapUpdateFailureData;

View File

@@ -147,7 +147,7 @@ typedef struct xl_heap_update
TransactionId old_xmax; /* xmax of the old tuple */
TransactionId new_xmax; /* xmax of the new tuple */
ItemPointerData newtid; /* new inserted tuple id */
uint8 old_infobits_set; /* infomask bits to set on old tuple */
uint8 old_infobits_set; /* infomask bits to set on old tuple */
bool all_visible_cleared; /* PD_ALL_VISIBLE was cleared */
bool new_all_visible_cleared; /* same for the page of newtid */
/* NEW TUPLE xl_heap_header AND TUPLE DATA FOLLOWS AT END OF STRUCT */
@@ -224,7 +224,7 @@ typedef struct xl_heap_lock
typedef struct xl_heap_lock_updated
{
xl_heaptid target;
TransactionId xmax;
TransactionId xmax;
uint8 infobits_set;
} xl_heap_lock_updated;

View File

@@ -153,6 +153,7 @@ struct HeapTupleHeaderData
/* MORE DATA FOLLOWS AT END OF STRUCT */
};
/* typedef appears in tupbasics.h */
/*
@@ -167,7 +168,7 @@ struct HeapTupleHeaderData
#define HEAP_XMAX_EXCL_LOCK 0x0040 /* xmax is exclusive locker */
#define HEAP_XMAX_LOCK_ONLY 0x0080 /* xmax, if valid, is only a locker */
/* xmax is a shared locker */
/* xmax is a shared locker */
#define HEAP_XMAX_SHR_LOCK (HEAP_XMAX_EXCL_LOCK | HEAP_XMAX_KEYSHR_LOCK)
#define HEAP_LOCK_MASK (HEAP_XMAX_SHR_LOCK | HEAP_XMAX_EXCL_LOCK | \
@@ -206,11 +207,11 @@ struct HeapTupleHeaderData
* Use these to test whether a particular lock is applied to a tuple
*/
#define HEAP_XMAX_IS_SHR_LOCKED(infomask) \
(((infomask) & HEAP_LOCK_MASK) == HEAP_XMAX_SHR_LOCK)
(((infomask) & HEAP_LOCK_MASK) == HEAP_XMAX_SHR_LOCK)
#define HEAP_XMAX_IS_EXCL_LOCKED(infomask) \
(((infomask) & HEAP_LOCK_MASK) == HEAP_XMAX_EXCL_LOCK)
(((infomask) & HEAP_LOCK_MASK) == HEAP_XMAX_EXCL_LOCK)
#define HEAP_XMAX_IS_KEYSHR_LOCKED(infomask) \
(((infomask) & HEAP_LOCK_MASK) == HEAP_XMAX_KEYSHR_LOCK)
(((infomask) & HEAP_LOCK_MASK) == HEAP_XMAX_KEYSHR_LOCK)
/* turn these all off when Xmax is to change */
#define HEAP_XMAX_BITS (HEAP_XMAX_COMMITTED | HEAP_XMAX_INVALID | \
@@ -527,6 +528,7 @@ struct MinimalTupleData
/* MORE DATA FOLLOWS AT END OF STRUCT */
};
/* typedef appears in htup.h */

View File

@@ -51,8 +51,8 @@ typedef enum
typedef struct MultiXactMember
{
TransactionId xid;
MultiXactStatus status;
TransactionId xid;
MultiXactStatus status;
} MultiXactMember;
@@ -84,7 +84,7 @@ extern MultiXactId MultiXactIdExpand(MultiXactId multi, TransactionId xid,
extern MultiXactId ReadNextMultiXactId(void);
extern bool MultiXactIdIsRunning(MultiXactId multi);
extern void MultiXactIdSetOldestMember(void);
extern int GetMultiXactIdMembers(MultiXactId multi, MultiXactMember **xids,
extern int GetMultiXactIdMembers(MultiXactId multi, MultiXactMember **xids,
bool allow_old);
extern bool MultiXactIdPrecedes(MultiXactId multi1, MultiXactId multi2);

View File

@@ -26,7 +26,7 @@ typedef enum RmgrIds
{
#include "access/rmgrlist.h"
RM_NEXT_ID
} RmgrIds;
} RmgrIds;
#undef PG_RMGR

View File

@@ -27,5 +27,4 @@
#define TableOidAttributeNumber (-7)
#define FirstLowInvalidHeapAttributeNumber (-8)
#endif /* SYSATTR_H */

View File

@@ -25,8 +25,8 @@
typedef struct
{
TimeLineID tli;
XLogRecPtr begin; /* inclusive */
XLogRecPtr end; /* exclusive, 0 means infinity */
XLogRecPtr begin; /* inclusive */
XLogRecPtr end; /* exclusive, 0 means infinity */
} TimeLineHistoryEntry;
extern List *readTimeLineHistory(TimeLineID targetTLI);

View File

@@ -264,7 +264,7 @@ extern XLogRecPtr XLogInsert(RmgrId rmid, uint8 info, XLogRecData *rdata);
extern void XLogFlush(XLogRecPtr RecPtr);
extern bool XLogBackgroundFlush(void);
extern bool XLogNeedsFlush(XLogRecPtr RecPtr);
extern int XLogFileInit(XLogSegNo segno, bool *use_existent, bool use_lock);
extern int XLogFileInit(XLogSegNo segno, bool *use_existent, bool use_lock);
extern int XLogFileOpen(XLogSegNo segno);
extern XLogRecPtr XLogSaveBufferForHint(Buffer buffer);

View File

@@ -127,10 +127,10 @@ typedef XLogLongPageHeaderData *XLogLongPageHeader;
* for deciding which segment to write given a pointer to a record end,
* for example.
*/
#define XLByteToSeg(xlrp, logSegNo) \
#define XLByteToSeg(xlrp, logSegNo) \
logSegNo = (xlrp) / XLogSegSize
#define XLByteToPrevSeg(xlrp, logSegNo) \
#define XLByteToPrevSeg(xlrp, logSegNo) \
logSegNo = ((xlrp) - 1) / XLogSegSize
/*
@@ -139,10 +139,10 @@ typedef XLogLongPageHeaderData *XLogLongPageHeader;
* For XLByteInSeg, do the computation at face value. For XLByteInPrevSeg,
* a boundary byte is taken to be in the previous segment.
*/
#define XLByteInSeg(xlrp, logSegNo) \
#define XLByteInSeg(xlrp, logSegNo) \
(((xlrp) / XLogSegSize) == (logSegNo))
#define XLByteInPrevSeg(xlrp, logSegNo) \
#define XLByteInPrevSeg(xlrp, logSegNo) \
((((xlrp) - 1) / XLogSegSize) == (logSegNo))
/* Check if an XLogRecPtr value is in a plausible range */
@@ -170,8 +170,8 @@ typedef XLogLongPageHeaderData *XLogLongPageHeader;
do { \
uint32 log; \
uint32 seg; \
sscanf(fname, "%08X%08X%08X", tli, &log, &seg); \
*logSegNo = (uint64) log * XLogSegmentsPerXLogId + seg; \
sscanf(fname, "%08X%08X%08X", tli, &log, &seg); \
*logSegNo = (uint64) log * XLogSegmentsPerXLogId + seg; \
} while (0)
#define XLogFilePath(path, tli, logSegNo) \
@@ -260,7 +260,7 @@ extern XLogRecPtr RequestXLogSwitch(void);
extern void GetOldestRestartPoint(XLogRecPtr *oldrecptr, TimeLineID *oldtli);
/*
* Exported for the functions in timeline.c and xlogarchive.c. Only valid
* Exported for the functions in timeline.c and xlogarchive.c. Only valid
* in the startup process.
*/
extern bool ArchiveRecoveryRequested;
@@ -276,7 +276,7 @@ extern bool RestoreArchivedFile(char *path, const char *xlogfname,
bool cleanupEnabled);
extern void ExecuteRecoveryCommand(char *command, char *commandName,
bool failOnerror);
extern void KeepFileRestoredFromArchive(char *path, char *xlogfname);
extern void KeepFileRestoredFromArchive(char *path, char *xlogfname);
extern void XLogArchiveNotify(const char *xlog);
extern void XLogArchiveNotifySeg(XLogSegNo segno);
extern void XLogArchiveForceDone(const char *xlog);

View File

@@ -53,7 +53,7 @@
#include "pg_config.h"
#include "pg_config_manual.h" /* must be after pg_config.h */
#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
@@ -573,7 +573,6 @@ typedef NameData *Name;
#define AssertMacro(condition) ((void)true)
#define AssertArg(condition)
#define AssertState(condition)
#elif defined(FRONTEND)
#include <assert.h>
@@ -581,8 +580,7 @@ typedef NameData *Name;
#define AssertMacro(p) ((void) assert(p))
#define AssertArg(condition) assert(condition)
#define AssertState(condition) assert(condition)
#else /* USE_ASSERT_CHECKING && !FRONTEND */
#else /* USE_ASSERT_CHECKING && !FRONTEND */
/*
* Trap
@@ -618,8 +616,7 @@ typedef NameData *Name;
#define AssertState(condition) \
Trap(!(condition), "BadState")
#endif /* USE_ASSERT_CHECKING && !FRONTEND */
#endif /* USE_ASSERT_CHECKING && !FRONTEND */
/*
@@ -629,7 +626,7 @@ typedef NameData *Name;
* throw a compile error using the "errmessage" (a string literal).
*
* gcc 4.6 and up supports _Static_assert(), but there are bizarre syntactic
* placement restrictions. These macros make it safe to use as a statement
* placement restrictions. These macros make it safe to use as a statement
* or in an expression, respectively.
*
* Otherwise we fall back on a kluge that assumes the compiler will complain
@@ -641,12 +638,12 @@ typedef NameData *Name;
do { _Static_assert(condition, errmessage); } while(0)
#define StaticAssertExpr(condition, errmessage) \
({ StaticAssertStmt(condition, errmessage); true; })
#else /* !HAVE__STATIC_ASSERT */
#else /* !HAVE__STATIC_ASSERT */
#define StaticAssertStmt(condition, errmessage) \
((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 */
/*
@@ -667,14 +664,14 @@ typedef NameData *Name;
#define AssertVariableIsOfTypeMacro(varname, typename) \
((void) StaticAssertExpr(__builtin_types_compatible_p(__typeof__(varname), typename), \
CppAsString(varname) " does not have type " CppAsString(typename)))
#else /* !HAVE__BUILTIN_TYPES_COMPATIBLE_P */
#else /* !HAVE__BUILTIN_TYPES_COMPATIBLE_P */
#define AssertVariableIsOfType(varname, typename) \
StaticAssertStmt(sizeof(varname) == sizeof(typename), \
CppAsString(varname) " does not have type " CppAsString(typename))
#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 */
/* ----------------------------------------------------------------
@@ -841,7 +838,7 @@ typedef NameData *Name;
*
* The function bodies must be defined in the module header prefixed by
* STATIC_IF_INLINE, protected by a cpp symbol that the module's .c file must
* define. If the compiler doesn't support inline functions, the function
* define. If the compiler doesn't support inline functions, the function
* definitions are pulled in by the .c file as regular (not inline) symbols.
*
* The header must also declare the functions' prototypes, protected by
@@ -851,7 +848,7 @@ typedef NameData *Name;
#define STATIC_IF_INLINE static inline
#else
#define STATIC_IF_INLINE
#endif /* PG_USE_INLINE */
#endif /* PG_USE_INLINE */
/* ----------------------------------------------------------------
* Section 8: random stuff

View File

@@ -99,7 +99,7 @@ extern List *AddRelationNewConstraints(Relation rel,
bool is_internal);
extern void StoreAttrDefault(Relation rel, AttrNumber attnum,
Node *expr, bool is_internal);
Node *expr, bool is_internal);
extern Node *cookDefault(ParseState *pstate,
Node *raw_default,

View File

@@ -237,7 +237,7 @@ DECLARE_UNIQUE_INDEX(pg_trigger_oid_index, 2702, on pg_trigger using btree(oid o
DECLARE_UNIQUE_INDEX(pg_event_trigger_evtname_index, 3467, on pg_event_trigger using btree(evtname name_ops));
#define EventTriggerNameIndexId 3467
DECLARE_UNIQUE_INDEX(pg_event_trigger_oid_index, 3468, on pg_event_trigger using btree(oid oid_ops));
#define EventTriggerOidIndexId 3468
#define EventTriggerOidIndexId 3468
DECLARE_UNIQUE_INDEX(pg_ts_config_cfgname_index, 3608, on pg_ts_config using btree(cfgname name_ops, cfgnamespace oid_ops));
#define TSConfigNameNspIndexId 3608

View File

@@ -54,9 +54,9 @@ typedef enum ObjectAccessType
typedef struct
{
/*
* This flag informs extensions whether the context of this creation
* is invoked by user's operations, or not. E.g, it shall be dealt
* as internal stuff on toast tables or indexes due to type changes.
* This flag informs extensions whether the context of this creation is
* invoked by user's operations, or not. E.g, it shall be dealt as
* internal stuff on toast tables or indexes due to type changes.
*/
bool is_internal;
} ObjectAccessPostCreate;
@@ -79,19 +79,18 @@ typedef struct
typedef struct
{
/*
* This identifier is used when system catalog takes two IDs
* to identify a particular tuple of the catalog.
* It is only used when the caller want to identify an entry
* of pg_inherits, pg_db_role_setting or pg_user_mapping.
* Elsewhere, InvalidOid should be set.
* This identifier is used when system catalog takes two IDs to identify a
* particular tuple of the catalog. It is only used when the caller want
* to identify an entry of pg_inherits, pg_db_role_setting or
* pg_user_mapping. Elsewhere, InvalidOid should be set.
*/
Oid auxiliary_id;
/*
* If this flag is set, the user hasn't requested that the object be
* altered, but we're doing it anyway for some internal reason.
* Permissions-checking hooks may want to skip checks if, say, we're
* alter the constraints of a temporary heap during CLUSTER.
* Permissions-checking hooks may want to skip checks if, say, we're alter
* the constraints of a temporary heap during CLUSTER.
*/
bool is_internal;
} ObjectAccessPostAlter;
@@ -108,12 +107,11 @@ typedef struct
bool ereport_on_violation;
/*
* This is, in essence, an out parameter. Core code should
* initialize this to true, and any extension that wants to deny
* access should reset it to false. But an extension should be
* careful never to store a true value here, so that in case there are
* multiple extensions access is only allowed if all extensions
* agree.
* This is, in essence, an out parameter. Core code should initialize
* this to true, and any extension that wants to deny access should reset
* it to false. But an extension should be careful never to store a true
* value here, so that in case there are multiple extensions access is
* only allowed if all extensions agree.
*/
bool result;
} ObjectAccessNamespaceSearch;
@@ -130,11 +128,11 @@ extern PGDLLIMPORT object_access_hook_type object_access_hook;
/* Core code uses these functions to call the hook (see macros below). */
extern void RunObjectPostCreateHook(Oid classId, Oid objectId, int subId,
bool is_internal);
bool is_internal);
extern void RunObjectDropHook(Oid classId, Oid objectId, int subId,
int dropflags);
int dropflags);
extern void RunObjectPostAlterHook(Oid classId, Oid objectId, int subId,
Oid auxiliaryId, bool is_internal);
Oid auxiliaryId, bool is_internal);
extern bool RunNamespaceSearchHook(Oid objectId, bool ereport_on_volation);
extern void RunFunctionExecuteHook(Oid objectId);

View File

@@ -38,18 +38,18 @@ extern void check_object_ownership(Oid roleid,
extern Oid get_object_namespace(const ObjectAddress *address);
extern bool is_objectclass_supported(Oid class_id);
extern Oid get_object_oid_index(Oid class_id);
extern int get_object_catcache_oid(Oid class_id);
extern int get_object_catcache_name(Oid class_id);
extern AttrNumber get_object_attnum_name(Oid class_id);
extern AttrNumber get_object_attnum_namespace(Oid class_id);
extern AttrNumber get_object_attnum_owner(Oid class_id);
extern AttrNumber get_object_attnum_acl(Oid class_id);
extern AclObjectKind get_object_aclkind(Oid class_id);
extern bool get_object_namensp_unique(Oid class_id);
extern bool is_objectclass_supported(Oid class_id);
extern Oid get_object_oid_index(Oid class_id);
extern int get_object_catcache_oid(Oid class_id);
extern int get_object_catcache_name(Oid class_id);
extern AttrNumber get_object_attnum_name(Oid class_id);
extern AttrNumber get_object_attnum_namespace(Oid class_id);
extern AttrNumber get_object_attnum_owner(Oid class_id);
extern AttrNumber get_object_attnum_acl(Oid class_id);
extern AclObjectKind get_object_aclkind(Oid class_id);
extern bool get_object_namensp_unique(Oid class_id);
extern HeapTuple get_catalog_object_by_oid(Relation catalog,
extern HeapTuple get_catalog_object_by_oid(Relation catalog,
Oid objectId);
extern char *getObjectDescription(const ObjectAddress *object);

View File

@@ -66,7 +66,7 @@ CATALOG(pg_class,1259) BKI_BOOTSTRAP BKI_ROWTYPE_OID(83) BKI_SCHEMA_MACRO
bool relhasrules; /* has (or has had) any rules */
bool relhastriggers; /* has (or has had) any TRIGGERs */
bool relhassubclass; /* has (or has had) derived classes */
bool relispopulated; /* matview currently holds query results */
bool relispopulated; /* matview currently holds query results */
TransactionId relfrozenxid; /* all Xids < this are frozen in this rel */
TransactionId relminmxid; /* all multixacts in this rel are >= this.
* this is really a MultiXactId */

View File

@@ -246,7 +246,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);

View File

@@ -43,7 +43,7 @@ typedef struct CheckPoint
MultiXactOffset nextMultiOffset; /* next free MultiXact offset */
TransactionId oldestXid; /* cluster-wide minimum datfrozenxid */
Oid oldestXidDB; /* database with minimum datfrozenxid */
MultiXactId oldestMulti; /* cluster-wide minimum datminmxid */
MultiXactId oldestMulti; /* cluster-wide minimum datminmxid */
Oid oldestMultiDB; /* database with minimum datminmxid */
pg_time_t time; /* time stamp of checkpoint */
@@ -127,7 +127,7 @@ typedef struct ControlFileData
CheckPoint checkPointCopy; /* copy of last check point record */
XLogRecPtr unloggedLSN; /* current fake LSN value, for unlogged rels */
XLogRecPtr unloggedLSN; /* current fake LSN value, for unlogged rels */
/*
* These two values determine the minimum point we must recover up to

View File

@@ -65,7 +65,7 @@ typedef FormData_pg_enum *Form_pg_enum;
extern void EnumValuesCreate(Oid enumTypeOid, List *vals);
extern void EnumValuesDelete(Oid enumTypeOid);
extern void AddEnumLabel(Oid enumTypeOid, const char *newVal,
const char *neighbor, bool newValIsAfter,
bool skipIfExists);
const char *neighbor, bool newValIsAfter,
bool skipIfExists);
#endif /* PG_ENUM_H */

View File

@@ -26,7 +26,7 @@
* typedef struct FormData_pg_event_trigger
* ----------------
*/
#define EventTriggerRelationId 3466
#define EventTriggerRelationId 3466
CATALOG(pg_event_trigger,3466)
{
@@ -36,8 +36,9 @@ CATALOG(pg_event_trigger,3466)
Oid evtfoid; /* OID of function to be called */
char evtenabled; /* trigger's firing configuration WRT
* session_replication_role */
#ifdef CATALOG_VARLEN
text evttags[1]; /* command TAGs this event trigger targets */
text evttags[1]; /* command TAGs this event trigger targets */
#endif
} FormData_pg_event_trigger;

View File

@@ -1732,7 +1732,7 @@ DATA(insert OID = 3964 ( "->" PGNSP PGUID b f f 114 23 114 0 0 json_array_el
DESCR("get json array element");
DATA(insert OID = 3965 ( "->>" PGNSP PGUID b f f 114 23 25 0 0 json_array_element_text - - ));
DESCR("get json array element as text");
DATA(insert OID = 3966 ( "#>" PGNSP PGUID b f f 114 1009 114 0 0 json_extract_path_op - - ));
DATA(insert OID = 3966 ( "#>" PGNSP PGUID b f f 114 1009 114 0 0 json_extract_path_op - - ));
DESCR("get value from json with path elements");
DATA(insert OID = 3967 ( "#>>" PGNSP PGUID b f f 114 1009 25 0 0 json_extract_path_text_op - - ));
DESCR("get value from json as text with path elements");

View File

@@ -869,7 +869,7 @@ DATA(insert OID = 2331 ( unnest PGNSP PGUID 12 1 100 0 0 f f f f t t i 1 0
DESCR("expand array to set of rows");
DATA(insert OID = 3167 ( array_remove PGNSP PGUID 12 1 0 0 0 f f f f f f i 2 0 2277 "2277 2283" _null_ _null_ _null_ _null_ array_remove _null_ _null_ _null_ ));
DESCR("remove any occurrences of an element from an array");
DATA(insert OID = 3168 ( array_replace PGNSP PGUID 12 1 0 0 0 f f f f f f i 3 0 2277 "2277 2283 2283" _null_ _null_ _null_ _null_ array_replace _null_ _null_ _null_ ));
DATA(insert OID = 3168 ( array_replace PGNSP PGUID 12 1 0 0 0 f f f f f f i 3 0 2277 "2277 2283 2283" _null_ _null_ _null_ _null_ array_replace _null_ _null_ _null_ ));
DESCR("replace any occurrences of an element in an array");
DATA(insert OID = 2333 ( array_agg_transfn PGNSP PGUID 12 1 0 0 0 f f f f f f i 2 0 2281 "2281 2283" _null_ _null_ _null_ _null_ array_agg_transfn _null_ _null_ _null_ ));
DESCR("aggregate transition function");
@@ -1052,7 +1052,7 @@ DATA(insert OID = 3171 ( lo_tell64 PGNSP PGUID 12 1 0 0 0 f f f f t f v 1 0
DESCR("large object position (64 bit)");
DATA(insert OID = 1004 ( lo_truncate PGNSP PGUID 12 1 0 0 0 f f f f t f v 2 0 23 "23 23" _null_ _null_ _null_ _null_ lo_truncate _null_ _null_ _null_ ));
DESCR("truncate large object");
DATA(insert OID = 3172 ( lo_truncate64 PGNSP PGUID 12 1 0 0 0 f f f f t f v 2 0 23 "23 20" _null_ _null_ _null_ _null_ lo_truncate64 _null_ _null_ _null_ ));
DATA(insert OID = 3172 ( lo_truncate64 PGNSP PGUID 12 1 0 0 0 f f f f t f v 2 0 23 "23 20" _null_ _null_ _null_ _null_ lo_truncate64 _null_ _null_ _null_ ));
DESCR("truncate large object (64 bit)");
DATA(insert OID = 959 ( on_pl PGNSP PGUID 12 1 0 0 0 f f f f t f i 2 0 16 "600 628" _null_ _null_ _null_ _null_ on_pl _null_ _null_ _null_ ));
@@ -3478,7 +3478,7 @@ DATA(insert OID = 2301 ( trigger_out PGNSP PGUID 12 1 0 0 0 f f f f t f i 1 0
DESCR("I/O");
DATA(insert OID = 3594 ( event_trigger_in PGNSP PGUID 12 1 0 0 0 f f f f f f i 1 0 3838 "2275" _null_ _null_ _null_ _null_ event_trigger_in _null_ _null_ _null_ ));
DESCR("I/O");
DATA(insert OID = 3595 ( event_trigger_out PGNSP PGUID 12 1 0 0 0 f f f f t f i 1 0 2275 "3838" _null_ _null_ _null_ _null_ event_trigger_out _null_ _null_ _null_ ));
DATA(insert OID = 3595 ( event_trigger_out PGNSP PGUID 12 1 0 0 0 f f f f t f i 1 0 2275 "3838" _null_ _null_ _null_ _null_ event_trigger_out _null_ _null_ _null_ ));
DESCR("I/O");
DATA(insert OID = 2302 ( language_handler_in PGNSP PGUID 12 1 0 0 0 f f f f f f i 1 0 2280 "2275" _null_ _null_ _null_ _null_ language_handler_in _null_ _null_ _null_ ));
DESCR("I/O");
@@ -4107,42 +4107,42 @@ DATA(insert OID = 3155 ( row_to_json PGNSP PGUID 12 1 0 0 0 f f f f t f s 1
DESCR("map row to json");
DATA(insert OID = 3156 ( row_to_json PGNSP PGUID 12 1 0 0 0 f f f f t f s 2 0 114 "2249 16" _null_ _null_ _null_ _null_ row_to_json_pretty _null_ _null_ _null_ ));
DESCR("map row to json with optional pretty printing");
DATA(insert OID = 3173 ( json_agg_transfn PGNSP PGUID 12 1 0 0 0 f f f f f f i 2 0 2281 "2281 2283" _null_ _null_ _null_ _null_ json_agg_transfn _null_ _null_ _null_ ));
DATA(insert OID = 3173 ( json_agg_transfn PGNSP PGUID 12 1 0 0 0 f f f f f f i 2 0 2281 "2281 2283" _null_ _null_ _null_ _null_ json_agg_transfn _null_ _null_ _null_ ));
DESCR("json aggregate transition function");
DATA(insert OID = 3174 ( json_agg_finalfn PGNSP PGUID 12 1 0 0 0 f f f f f f i 1 0 114 "2281" _null_ _null_ _null_ _null_ json_agg_finalfn _null_ _null_ _null_ ));
DATA(insert OID = 3174 ( json_agg_finalfn PGNSP PGUID 12 1 0 0 0 f f f f f f i 1 0 114 "2281" _null_ _null_ _null_ _null_ json_agg_finalfn _null_ _null_ _null_ ));
DESCR("json aggregate final function");
DATA(insert OID = 3175 ( json_agg PGNSP PGUID 12 1 0 0 0 t f f f f f i 1 0 114 "2283" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ));
DESCR("aggregate input into json");
DATA(insert OID = 3176 ( to_json PGNSP PGUID 12 1 0 0 0 f f f f t f s 1 0 114 "2283" _null_ _null_ _null_ _null_ to_json _null_ _null_ _null_ ));
DESCR("map input to json");
DATA(insert OID = 3947 ( json_object_field PGNSP PGUID 12 1 0 0 0 f f f f t f i 2 0 114 "114 25" _null_ _null_ "{from_json, field_name}" _null_ json_object_field _null_ _null_ _null_ ));
DATA(insert OID = 3947 ( json_object_field PGNSP PGUID 12 1 0 0 0 f f f f t f i 2 0 114 "114 25" _null_ _null_ "{from_json, field_name}" _null_ json_object_field _null_ _null_ _null_ ));
DESCR("get json object field");
DATA(insert OID = 3948 ( json_object_field_text PGNSP PGUID 12 1 0 0 0 f f f f t f i 2 0 25 "114 25" _null_ _null_ "{from_json, field_name}" _null_ json_object_field_text _null_ _null_ _null_ ));
DATA(insert OID = 3948 ( json_object_field_text PGNSP PGUID 12 1 0 0 0 f f f f t f i 2 0 25 "114 25" _null_ _null_ "{from_json, field_name}" _null_ json_object_field_text _null_ _null_ _null_ ));
DESCR("get json object field as text");
DATA(insert OID = 3949 ( json_array_element PGNSP PGUID 12 1 0 0 0 f f f f t f i 2 0 114 "114 23" _null_ _null_ "{from_json, element_index}" _null_ json_array_element _null_ _null_ _null_ ));
DATA(insert OID = 3949 ( json_array_element PGNSP PGUID 12 1 0 0 0 f f f f t f i 2 0 114 "114 23" _null_ _null_ "{from_json, element_index}" _null_ json_array_element _null_ _null_ _null_ ));
DESCR("get json array element");
DATA(insert OID = 3950 ( json_array_element_text PGNSP PGUID 12 1 0 0 0 f f f f t f i 2 0 25 "114 23" _null_ _null_ "{from_json, element_index}" _null_ json_array_element_text _null_ _null_ _null_ ));
DATA(insert OID = 3950 ( json_array_element_text PGNSP PGUID 12 1 0 0 0 f f f f t f i 2 0 25 "114 23" _null_ _null_ "{from_json, element_index}" _null_ json_array_element_text _null_ _null_ _null_ ));
DESCR("get json array element as text");
DATA(insert OID = 3951 ( json_extract_path PGNSP PGUID 12 1 0 25 0 f f f f t f i 2 0 114 "114 1009" "{114,1009}" "{i,v}" "{from_json,path_elems}" _null_ json_extract_path _null_ _null_ _null_ ));
DATA(insert OID = 3951 ( json_extract_path PGNSP PGUID 12 1 0 25 0 f f f f t f i 2 0 114 "114 1009" "{114,1009}" "{i,v}" "{from_json,path_elems}" _null_ json_extract_path _null_ _null_ _null_ ));
DESCR("get value from json with path elements");
DATA(insert OID = 3952 ( json_extract_path_op PGNSP PGUID 12 1 0 0 0 f f f f t f i 2 0 114 "114 1009" _null_ _null_ "{from_json,path_elems}" _null_ json_extract_path _null_ _null_ _null_ ));
DATA(insert OID = 3952 ( json_extract_path_op PGNSP PGUID 12 1 0 0 0 f f f f t f i 2 0 114 "114 1009" _null_ _null_ "{from_json,path_elems}" _null_ json_extract_path _null_ _null_ _null_ ));
DESCR("get value from json with path elements");
DATA(insert OID = 3953 ( json_extract_path_text PGNSP PGUID 12 1 0 25 0 f f f f t f i 2 0 25 "114 1009" "{114,1009}" "{i,v}" "{from_json,path_elems}" _null_ json_extract_path_text _null_ _null_ _null_ ));
DESCR("get value from json as text with path elements");
DATA(insert OID = 3954 ( json_extract_path_text_op PGNSP PGUID 12 1 0 0 0 f f f f t f i 2 0 25 "114 1009" _null_ _null_ "{from_json,path_elems}" _null_ json_extract_path_text _null_ _null_ _null_ ));
DATA(insert OID = 3954 ( json_extract_path_text_op PGNSP PGUID 12 1 0 0 0 f f f f t f i 2 0 25 "114 1009" _null_ _null_ "{from_json,path_elems}" _null_ json_extract_path_text _null_ _null_ _null_ ));
DESCR("get value from json as text with path elements");
DATA(insert OID = 3955 ( json_array_elements PGNSP PGUID 12 1 100 0 0 f f f f t t i 1 0 114 "114" "{114,114}" "{i,o}" "{from_json,value}" _null_ json_array_elements _null_ _null_ _null_ ));
DATA(insert OID = 3955 ( json_array_elements PGNSP PGUID 12 1 100 0 0 f f f f t t i 1 0 114 "114" "{114,114}" "{i,o}" "{from_json,value}" _null_ json_array_elements _null_ _null_ _null_ ));
DESCR("key value pairs of a json object");
DATA(insert OID = 3956 ( json_array_length PGNSP PGUID 12 1 0 0 0 f f f f t f i 1 0 23 "114" _null_ _null_ _null_ _null_ json_array_length _null_ _null_ _null_ ));
DATA(insert OID = 3956 ( json_array_length PGNSP PGUID 12 1 0 0 0 f f f f t f i 1 0 23 "114" _null_ _null_ _null_ _null_ json_array_length _null_ _null_ _null_ ));
DESCR("length of json array");
DATA(insert OID = 3957 ( json_object_keys PGNSP PGUID 12 1 100 0 0 f f f f t t i 1 0 25 "114" _null_ _null_ _null_ _null_ json_object_keys _null_ _null_ _null_ ));
DATA(insert OID = 3957 ( json_object_keys PGNSP PGUID 12 1 100 0 0 f f f f t t i 1 0 25 "114" _null_ _null_ _null_ _null_ json_object_keys _null_ _null_ _null_ ));
DESCR("get json object keys");
DATA(insert OID = 3958 ( json_each PGNSP PGUID 12 1 100 0 0 f f f f t t i 1 0 2249 "114" "{114,25,114}" "{i,o,o}" "{from_json,key,value}" _null_ json_each _null_ _null_ _null_ ));
DATA(insert OID = 3958 ( json_each PGNSP PGUID 12 1 100 0 0 f f f f t t i 1 0 2249 "114" "{114,25,114}" "{i,o,o}" "{from_json,key,value}" _null_ json_each _null_ _null_ _null_ ));
DESCR("key value pairs of a json object");
DATA(insert OID = 3959 ( json_each_text PGNSP PGUID 12 1 100 0 0 f f f f t t i 1 0 2249 "114" "{114,25,25}" "{i,o,o}" "{from_json,key,value}" _null_ json_each_text _null_ _null_ _null_ ));
DATA(insert OID = 3959 ( json_each_text PGNSP PGUID 12 1 100 0 0 f f f f t t i 1 0 2249 "114" "{114,25,25}" "{i,o,o}" "{from_json,key,value}" _null_ json_each_text _null_ _null_ _null_ ));
DESCR("key value pairs of a json object");
DATA(insert OID = 3960 ( json_populate_record PGNSP PGUID 12 1 0 0 0 f f f f f f s 3 0 2283 "2283 114 16" _null_ _null_ _null_ _null_ json_populate_record _null_ _null_ _null_ ));
DATA(insert OID = 3960 ( json_populate_record PGNSP PGUID 12 1 0 0 0 f f f f f f s 3 0 2283 "2283 114 16" _null_ _null_ _null_ _null_ json_populate_record _null_ _null_ _null_ ));
DESCR("get record fields from a json object");
DATA(insert OID = 3961 ( json_populate_recordset PGNSP PGUID 12 1 100 0 0 f f f f f t s 3 0 2283 "2283 114 16" _null_ _null_ _null_ _null_ json_populate_recordset _null_ _null_ _null_ ));
DESCR("get set of records with fields from a json array of objects");
@@ -4710,9 +4710,9 @@ DESCR("SP-GiST support for radix tree over text");
DATA(insert OID = 4031 ( spg_text_leaf_consistent PGNSP PGUID 12 1 0 0 0 f f f f t f i 2 0 16 "2281 2281" _null_ _null_ _null_ _null_ spg_text_leaf_consistent _null_ _null_ _null_ ));
DESCR("SP-GiST support for radix tree over text");
DATA(insert OID = 3469 ( spg_range_quad_config PGNSP PGUID 12 1 0 0 0 f f f f t f i 2 0 2278 "2281 2281" _null_ _null_ _null_ _null_ spg_range_quad_config _null_ _null_ _null_ ));
DATA(insert OID = 3469 ( spg_range_quad_config PGNSP PGUID 12 1 0 0 0 f f f f t f i 2 0 2278 "2281 2281" _null_ _null_ _null_ _null_ spg_range_quad_config _null_ _null_ _null_ ));
DESCR("SP-GiST support for quad tree over range");
DATA(insert OID = 3470 ( spg_range_quad_choose PGNSP PGUID 12 1 0 0 0 f f f f t f i 2 0 2278 "2281 2281" _null_ _null_ _null_ _null_ spg_range_quad_choose _null_ _null_ _null_ ));
DATA(insert OID = 3470 ( spg_range_quad_choose PGNSP PGUID 12 1 0 0 0 f f f f t f i 2 0 2278 "2281 2281" _null_ _null_ _null_ _null_ spg_range_quad_choose _null_ _null_ _null_ ));
DESCR("SP-GiST support for quad tree over range");
DATA(insert OID = 3471 ( spg_range_quad_picksplit PGNSP PGUID 12 1 0 0 0 f f f f t f i 2 0 2278 "2281 2281" _null_ _null_ _null_ _null_ spg_range_quad_picksplit _null_ _null_ _null_ ));
DESCR("SP-GiST support for quad tree over range");

View File

@@ -286,7 +286,7 @@ typedef FormData_pg_statistic *Form_pg_statistic;
* Unlike a regular scalar histogram, this is actually two histograms combined
* into a single array, with the lower bounds of each value forming a
* histogram of lower bounds, and the upper bounds a histogram of upper
* bounds. Only non-NULL, non-empty ranges are included.
* bounds. Only non-NULL, non-empty ranges are included.
*/
#define STATISTIC_KIND_BOUNDS_HISTOGRAM 7

View File

@@ -18,13 +18,13 @@
#include "nodes/parsenodes.h"
#include "utils/relcache.h"
extern Oid ExecRenameStmt(RenameStmt *stmt);
extern Oid ExecRenameStmt(RenameStmt *stmt);
extern Oid ExecAlterObjectSchemaStmt(AlterObjectSchemaStmt *stmt);
extern Oid ExecAlterObjectSchemaStmt(AlterObjectSchemaStmt *stmt);
extern Oid AlterObjectNamespace_oid(Oid classId, Oid objid, Oid nspOid,
ObjectAddresses *objsMoved);
extern Oid ExecAlterOwnerStmt(AlterOwnerStmt *stmt);
extern Oid ExecAlterOwnerStmt(AlterOwnerStmt *stmt);
extern void AlterObjectOwner_internal(Relation catalog, Oid objectId,
Oid new_ownerId);

View File

@@ -17,7 +17,7 @@
#include "nodes/parsenodes.h"
extern Oid DefineCollation(List *names, List *parameters);
extern Oid DefineCollation(List *names, List *parameters);
extern void IsThereCollationInNamespace(const char *collname, Oid nspOid);
#endif /* COLLATIONCMDS_H */

View File

@@ -29,7 +29,7 @@
*------------------------------------------------------------------
*/
extern Oid CommentObject(CommentStmt *stmt);
extern Oid CommentObject(CommentStmt *stmt);
extern void DeleteComments(Oid oid, Oid classoid, int32 subid);

View File

@@ -17,6 +17,6 @@
#include "nodes/parsenodes.h"
extern Oid CreateConversionCommand(CreateConversionStmt *parsetree);
extern Oid CreateConversionCommand(CreateConversionStmt *parsetree);
#endif /* CONVERSIONCMDS_H */

View File

@@ -22,7 +22,7 @@
typedef struct CopyStateData *CopyState;
extern Oid DoCopy(const CopyStmt *stmt, const char *queryString,
uint64 *processed);
uint64 *processed);
extern void ProcessCopyOptions(CopyState cstate, bool is_from, List *options);
extern CopyState BeginCopyFrom(Relation rel, const char *filename,

View File

@@ -52,12 +52,12 @@ typedef struct xl_dbase_drop_rec
Oid tablespace_id;
} xl_dbase_drop_rec;
extern Oid createdb(const CreatedbStmt *stmt);
extern Oid createdb(const CreatedbStmt *stmt);
extern void dropdb(const char *dbname, bool missing_ok);
extern Oid RenameDatabase(const char *oldname, const char *newname);
extern Oid AlterDatabase(AlterDatabaseStmt *stmt, bool isTopLevel);
extern Oid AlterDatabaseSet(AlterDatabaseSetStmt *stmt);
extern Oid AlterDatabaseOwner(const char *dbname, Oid newOwnerId);
extern Oid RenameDatabase(const char *oldname, const char *newname);
extern Oid AlterDatabase(AlterDatabaseStmt *stmt, bool isTopLevel);
extern Oid AlterDatabaseSet(AlterDatabaseSetStmt *stmt);
extern Oid AlterDatabaseOwner(const char *dbname, Oid newOwnerId);
extern Oid get_database_oid(const char *dbname, bool missingok);
extern char *get_database_name(Oid dbid);

View File

@@ -26,8 +26,8 @@ extern Oid DefineIndex(IndexStmt *stmt,
bool check_rights,
bool skip_build,
bool quiet);
extern Oid ReindexIndex(RangeVar *indexRelation);
extern Oid ReindexTable(RangeVar *relation);
extern Oid ReindexIndex(RangeVar *indexRelation);
extern Oid ReindexTable(RangeVar *relation);
extern Oid ReindexDatabase(const char *databaseName,
bool do_system, bool do_user);
extern char *makeObjectName(const char *name1, const char *name2,
@@ -42,12 +42,12 @@ extern bool CheckIndexCompatible(Oid oldId,
extern Oid GetDefaultOpClass(Oid type_id, Oid am_id);
/* commands/functioncmds.c */
extern Oid CreateFunction(CreateFunctionStmt *stmt, const char *queryString);
extern Oid CreateFunction(CreateFunctionStmt *stmt, const char *queryString);
extern void RemoveFunctionById(Oid funcOid);
extern void SetFunctionReturnType(Oid funcOid, Oid newRetType);
extern void SetFunctionArgType(Oid funcOid, int argIndex, Oid newArgType);
extern Oid AlterFunction(AlterFunctionStmt *stmt);
extern Oid CreateCast(CreateCastStmt *stmt);
extern Oid AlterFunction(AlterFunctionStmt *stmt);
extern Oid CreateCast(CreateCastStmt *stmt);
extern void DropCastById(Oid castOid);
extern void IsThereFunctionInNamespace(const char *proname, int pronargs,
oidvector proargtypes, Oid nspOid);
@@ -55,7 +55,7 @@ extern void ExecuteDoStmt(DoStmt *stmt);
extern Oid get_cast_oid(Oid sourcetypeid, Oid targettypeid, bool missing_ok);
/* commands/operatorcmds.c */
extern Oid DefineOperator(List *names, List *parameters);
extern Oid DefineOperator(List *names, List *parameters);
extern void RemoveOperatorById(Oid operOid);
/* commands/aggregatecmds.c */
@@ -63,53 +63,53 @@ extern Oid DefineAggregate(List *name, List *args, bool oldstyle,
List *parameters);
/* commands/opclasscmds.c */
extern Oid DefineOpClass(CreateOpClassStmt *stmt);
extern Oid DefineOpFamily(CreateOpFamilyStmt *stmt);
extern Oid AlterOpFamily(AlterOpFamilyStmt *stmt);
extern Oid DefineOpClass(CreateOpClassStmt *stmt);
extern Oid DefineOpFamily(CreateOpFamilyStmt *stmt);
extern Oid AlterOpFamily(AlterOpFamilyStmt *stmt);
extern void RemoveOpClassById(Oid opclassOid);
extern void RemoveOpFamilyById(Oid opfamilyOid);
extern void RemoveAmOpEntryById(Oid entryOid);
extern void RemoveAmProcEntryById(Oid entryOid);
extern void IsThereOpClassInNamespace(const char *opcname, Oid opcmethod,
Oid opcnamespace);
Oid opcnamespace);
extern void IsThereOpFamilyInNamespace(const char *opfname, Oid opfmethod,
Oid opfnamespace);
Oid opfnamespace);
extern Oid get_am_oid(const char *amname, bool missing_ok);
extern Oid get_opclass_oid(Oid amID, List *opclassname, bool missing_ok);
extern Oid get_opfamily_oid(Oid amID, List *opfamilyname, bool missing_ok);
/* commands/tsearchcmds.c */
extern Oid DefineTSParser(List *names, List *parameters);
extern Oid DefineTSParser(List *names, List *parameters);
extern void RemoveTSParserById(Oid prsId);
extern Oid DefineTSDictionary(List *names, List *parameters);
extern Oid DefineTSDictionary(List *names, List *parameters);
extern void RemoveTSDictionaryById(Oid dictId);
extern Oid AlterTSDictionary(AlterTSDictionaryStmt *stmt);
extern Oid AlterTSDictionary(AlterTSDictionaryStmt *stmt);
extern Oid DefineTSTemplate(List *names, List *parameters);
extern Oid DefineTSTemplate(List *names, List *parameters);
extern void RemoveTSTemplateById(Oid tmplId);
extern Oid DefineTSConfiguration(List *names, List *parameters);
extern Oid DefineTSConfiguration(List *names, List *parameters);
extern void RemoveTSConfigurationById(Oid cfgId);
extern Oid AlterTSConfiguration(AlterTSConfigurationStmt *stmt);
extern Oid AlterTSConfiguration(AlterTSConfigurationStmt *stmt);
extern text *serialize_deflist(List *deflist);
extern List *deserialize_deflist(Datum txt);
/* commands/foreigncmds.c */
extern Oid AlterForeignServerOwner(const char *name, Oid newOwnerId);
extern Oid AlterForeignServerOwner(const char *name, Oid newOwnerId);
extern void AlterForeignServerOwner_oid(Oid, Oid newOwnerId);
extern Oid AlterForeignDataWrapperOwner(const char *name, Oid newOwnerId);
extern Oid AlterForeignDataWrapperOwner(const char *name, Oid newOwnerId);
extern void AlterForeignDataWrapperOwner_oid(Oid fwdId, Oid newOwnerId);
extern Oid CreateForeignDataWrapper(CreateFdwStmt *stmt);
extern Oid AlterForeignDataWrapper(AlterFdwStmt *stmt);
extern Oid CreateForeignDataWrapper(CreateFdwStmt *stmt);
extern Oid AlterForeignDataWrapper(AlterFdwStmt *stmt);
extern void RemoveForeignDataWrapperById(Oid fdwId);
extern Oid CreateForeignServer(CreateForeignServerStmt *stmt);
extern Oid AlterForeignServer(AlterForeignServerStmt *stmt);
extern Oid CreateForeignServer(CreateForeignServerStmt *stmt);
extern Oid AlterForeignServer(AlterForeignServerStmt *stmt);
extern void RemoveForeignServerById(Oid srvId);
extern Oid CreateUserMapping(CreateUserMappingStmt *stmt);
extern Oid AlterUserMapping(AlterUserMappingStmt *stmt);
extern Oid RemoveUserMapping(DropUserMappingStmt *stmt);
extern Oid CreateUserMapping(CreateUserMappingStmt *stmt);
extern Oid AlterUserMapping(AlterUserMappingStmt *stmt);
extern Oid RemoveUserMapping(DropUserMappingStmt *stmt);
extern void RemoveUserMappingById(Oid umId);
extern void CreateForeignTable(CreateForeignTableStmt *stmt, Oid relid);
extern Datum transformGenericOptions(Oid catalogId,

View File

@@ -21,9 +21,9 @@
typedef struct EventTriggerData
{
NodeTag type;
const char *event; /* event name */
Node *parsetree; /* parse tree */
const char *tag; /* command tag */
const char *event; /* event name */
Node *parsetree; /* parse tree */
const char *tag; /* command tag */
} EventTriggerData;
/*
@@ -33,12 +33,12 @@ typedef struct EventTriggerData
#define CALLED_AS_EVENT_TRIGGER(fcinfo) \
((fcinfo)->context != NULL && IsA((fcinfo)->context, EventTriggerData))
extern Oid CreateEventTrigger(CreateEventTrigStmt *stmt);
extern Oid CreateEventTrigger(CreateEventTrigStmt *stmt);
extern void RemoveEventTriggerById(Oid ctrigOid);
extern Oid get_event_trigger_oid(const char *trigname, bool missing_ok);
extern Oid AlterEventTrigger(AlterEventTrigStmt *stmt);
extern Oid AlterEventTriggerOwner(const char *name, Oid newOwnerId);
extern Oid AlterEventTrigger(AlterEventTrigStmt *stmt);
extern Oid AlterEventTriggerOwner(const char *name, Oid newOwnerId);
extern void AlterEventTriggerOwner_oid(Oid, Oid newOwnerId);
extern bool EventTriggerSupportsObjectType(ObjectType obtype);

View File

@@ -27,7 +27,7 @@ extern bool creating_extension;
extern Oid CurrentExtensionObject;
extern Oid CreateExtension(CreateExtensionStmt *stmt);
extern Oid CreateExtension(CreateExtensionStmt *stmt);
extern void RemoveExtensionById(Oid extId);
@@ -36,14 +36,14 @@ extern Oid InsertExtensionTuple(const char *extName, Oid extOwner,
Datum extConfig, Datum extCondition,
List *requiredExtensions);
extern Oid ExecAlterExtensionStmt(AlterExtensionStmt *stmt);
extern Oid ExecAlterExtensionStmt(AlterExtensionStmt *stmt);
extern Oid ExecAlterExtensionContentsStmt(AlterExtensionContentsStmt *stmt);
extern Oid ExecAlterExtensionContentsStmt(AlterExtensionContentsStmt *stmt);
extern Oid get_extension_oid(const char *extname, bool missing_ok);
extern char *get_extension_name(Oid ext_oid);
extern Oid AlterExtensionNamespace(List *names, const char *newschema);
extern Oid AlterExtensionNamespace(List *names, const char *newschema);
extern void AlterExtensionOwner_oid(Oid extensionOid, Oid newOwnerId);

View File

@@ -23,7 +23,7 @@
extern void SetMatViewPopulatedState(Relation relation, bool newstate);
extern void ExecRefreshMatView(RefreshMatViewStmt *stmt, const char *queryString,
ParamListInfo params, char *completionTag);
ParamListInfo params, char *completionTag);
extern DestReceiver *CreateTransientRelDestReceiver(Oid oid);

View File

@@ -14,7 +14,7 @@
#include "nodes/parsenodes.h"
extern Oid CreateProceduralLanguage(CreatePLangStmt *stmt);
extern Oid CreateProceduralLanguage(CreatePLangStmt *stmt);
extern void DropProceduralLanguageById(Oid langOid);
extern bool PLTemplateExists(const char *languageName);
extern Oid get_language_oid(const char *langname, bool missing_ok);

View File

@@ -22,8 +22,8 @@ extern Oid CreateSchemaCommand(CreateSchemaStmt *parsetree,
extern void RemoveSchemaById(Oid schemaOid);
extern Oid RenameSchema(const char *oldname, const char *newname);
extern Oid AlterSchemaOwner(const char *name, Oid newOwnerId);
extern Oid RenameSchema(const char *oldname, const char *newname);
extern Oid AlterSchemaOwner(const char *name, Oid newOwnerId);
extern void AlterSchemaOwner_oid(Oid schemaOid, Oid newOwnerId);
#endif /* SCHEMACMDS_H */

View File

@@ -24,7 +24,7 @@ extern void DeleteSharedSecurityLabel(Oid objectId, Oid classId);
/*
* Statement and ESP hook support
*/
extern Oid ExecSecLabelStmt(SecLabelStmt *stmt);
extern Oid ExecSecLabelStmt(SecLabelStmt *stmt);
typedef void (*check_object_relabel_type) (const ObjectAddress *object,
const char *seclabel);

View File

@@ -71,8 +71,8 @@ extern Datum lastval(PG_FUNCTION_ARGS);
extern Datum pg_sequence_parameters(PG_FUNCTION_ARGS);
extern Oid DefineSequence(CreateSeqStmt *stmt);
extern Oid AlterSequence(AlterSeqStmt *stmt);
extern Oid DefineSequence(CreateSeqStmt *stmt);
extern Oid AlterSequence(AlterSeqStmt *stmt);
extern void ResetSequence(Oid seq_relid);
extern void seq_redo(XLogRecPtr lsn, XLogRecord *rptr);

View File

@@ -35,7 +35,7 @@ extern void ATExecChangeOwner(Oid relationOid, Oid newOwnerId, bool recursing, L
extern void AlterTableInternal(Oid relid, List *cmds, bool recurse);
extern Oid AlterTableNamespace(AlterObjectSchemaStmt *stmt);
extern Oid AlterTableNamespace(AlterObjectSchemaStmt *stmt);
extern void AlterTableNamespaceInternal(Relation rel, Oid oldNspOid,
Oid nspOid, ObjectAddresses *objsMoved);
@@ -51,11 +51,11 @@ extern void ExecuteTruncate(TruncateStmt *stmt);
extern void SetRelationHasSubclass(Oid relationId, bool relhassubclass);
extern Oid renameatt(RenameStmt *stmt);
extern Oid renameatt(RenameStmt *stmt);
extern Oid RenameConstraint(RenameStmt *stmt);
extern Oid RenameConstraint(RenameStmt *stmt);
extern Oid RenameRelation(RenameStmt *stmt);
extern Oid RenameRelation(RenameStmt *stmt);
extern void RenameRelationInternal(Oid myrelid,
const char *newrelname, bool is_internal);

View File

@@ -39,10 +39,10 @@ typedef struct TableSpaceOpts
float8 seq_page_cost;
} TableSpaceOpts;
extern Oid CreateTableSpace(CreateTableSpaceStmt *stmt);
extern Oid CreateTableSpace(CreateTableSpaceStmt *stmt);
extern void DropTableSpace(DropTableSpaceStmt *stmt);
extern Oid RenameTableSpace(const char *oldname, const char *newname);
extern Oid AlterTableSpaceOptions(AlterTableSpaceOptionsStmt *stmt);
extern Oid RenameTableSpace(const char *oldname, const char *newname);
extern Oid AlterTableSpaceOptions(AlterTableSpaceOptionsStmt *stmt);
extern void TablespaceCreateDbspace(Oid spcNode, Oid dbNode, bool isRedo);

View File

@@ -115,7 +115,7 @@ extern Oid CreateTrigger(CreateTrigStmt *stmt, const char *queryString,
extern void RemoveTriggerById(Oid trigOid);
extern Oid get_trigger_oid(Oid relid, const char *name, bool missing_ok);
extern Oid renametrig(RenameStmt *stmt);
extern Oid renametrig(RenameStmt *stmt);
extern void EnableDisableTrigger(Relation rel, const char *tgname,
char fires_when, bool skip_system);

View File

@@ -21,19 +21,19 @@
#define DEFAULT_TYPDELIM ','
extern Oid DefineType(List *names, List *parameters);
extern Oid DefineType(List *names, List *parameters);
extern void RemoveTypeById(Oid typeOid);
extern Oid DefineDomain(CreateDomainStmt *stmt);
extern Oid DefineEnum(CreateEnumStmt *stmt);
extern Oid DefineRange(CreateRangeStmt *stmt);
extern Oid AlterEnum(AlterEnumStmt *stmt, bool isTopLevel);
extern Oid DefineDomain(CreateDomainStmt *stmt);
extern Oid DefineEnum(CreateEnumStmt *stmt);
extern Oid DefineRange(CreateRangeStmt *stmt);
extern Oid AlterEnum(AlterEnumStmt *stmt, bool isTopLevel);
extern Oid DefineCompositeType(RangeVar *typevar, List *coldeflist);
extern Oid AssignTypeArrayOid(void);
extern Oid AlterDomainDefault(List *names, Node *defaultRaw);
extern Oid AlterDomainNotNull(List *names, bool notNull);
extern Oid AlterDomainAddConstraint(List *names, Node *constr);
extern Oid AlterDomainValidateConstraint(List *names, char *constrName);
extern Oid AlterDomainDefault(List *names, Node *defaultRaw);
extern Oid AlterDomainNotNull(List *names, bool notNull);
extern Oid AlterDomainAddConstraint(List *names, Node *constr);
extern Oid AlterDomainValidateConstraint(List *names, char *constrName);
extern Oid AlterDomainDropConstraint(List *names, const char *constrName,
DropBehavior behavior, bool missing_ok);
@@ -41,13 +41,13 @@ extern void checkDomainOwner(HeapTuple tup);
extern List *GetDomainConstraints(Oid typeOid);
extern Oid RenameType(RenameStmt *stmt);
extern Oid AlterTypeOwner(List *names, Oid newOwnerId, ObjectType objecttype);
extern Oid RenameType(RenameStmt *stmt);
extern Oid AlterTypeOwner(List *names, Oid newOwnerId, ObjectType objecttype);
extern void AlterTypeOwnerInternal(Oid typeOid, Oid newOwnerId,
bool hasDependEntry);
extern Oid AlterTypeNamespace(List *names, const char *newschema, ObjectType objecttype);
extern Oid AlterTypeNamespace(List *names, const char *newschema, ObjectType objecttype);
extern Oid AlterTypeNamespace_oid(Oid typeOid, Oid nspOid, ObjectAddresses *objsMoved);
extern Oid AlterTypeNamespaceInternal(Oid typeOid, Oid nspOid,
extern Oid AlterTypeNamespaceInternal(Oid typeOid, Oid nspOid,
bool isImplicitArray,
bool errorOnTableType,
ObjectAddresses *objsMoved);

View File

@@ -22,12 +22,12 @@ typedef void (*check_password_hook_type) (const char *username, const char *pass
extern PGDLLIMPORT check_password_hook_type check_password_hook;
extern Oid CreateRole(CreateRoleStmt *stmt);
extern Oid AlterRole(AlterRoleStmt *stmt);
extern Oid AlterRoleSet(AlterRoleSetStmt *stmt);
extern Oid CreateRole(CreateRoleStmt *stmt);
extern Oid AlterRole(AlterRoleStmt *stmt);
extern Oid AlterRoleSet(AlterRoleSetStmt *stmt);
extern void DropRole(DropRoleStmt *stmt);
extern void GrantRole(GrantRoleStmt *stmt);
extern Oid RenameRole(const char *oldname, const char *newname);
extern Oid RenameRole(const char *oldname, const char *newname);
extern void DropOwnedObjects(DropOwnedStmt *stmt);
extern void ReassignOwnedObjects(ReassignOwnedStmt *stmt);

View File

@@ -16,7 +16,7 @@
#include "nodes/parsenodes.h"
extern Oid DefineView(ViewStmt *stmt, const char *queryString);
extern Oid DefineView(ViewStmt *stmt, const char *queryString);
extern void StoreViewQuery(Oid viewOid, Query *viewParse, bool replace);

View File

@@ -13,7 +13,7 @@ extern char *pg_strdup(const char *in);
extern void *pg_malloc(size_t size);
extern void *pg_malloc0(size_t size);
extern void *pg_realloc(void *pointer, size_t size);
extern void pg_free(void *pointer);
extern void pg_free(void *pointer);
#include "utils/palloc.h"

View File

@@ -1,7 +1,7 @@
/*-------------------------------------------------------------------------
*
* relpath.h
* Declarations for relpath() and friends
* Declarations for relpath() and friends
*
* Portions Copyright (c) 1996-2013, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
@@ -38,4 +38,4 @@ extern char *relpathbackend(RelFileNode rnode, BackendId backend,
#define relpathperm(rnode, forknum) \
relpathbackend((rnode), InvalidBackendId, (forknum))
#endif /* RELPATH_H */
#endif /* RELPATH_H */

View File

@@ -35,11 +35,11 @@ typedef struct binaryheap
binaryheap_comparator bh_compare;
void *bh_arg;
Datum bh_nodes[FLEXIBLE_ARRAY_MEMBER];
} binaryheap;
} binaryheap;
extern binaryheap *binaryheap_allocate(int capacity,
binaryheap_comparator compare,
void *arg);
binaryheap_comparator compare,
void *arg);
extern void binaryheap_free(binaryheap *heap);
extern void binaryheap_add_unordered(binaryheap *heap, Datum d);
extern void binaryheap_build(binaryheap *heap);

View File

@@ -87,12 +87,12 @@ typedef struct HbaLine
typedef struct IdentLine
{
int linenumber;
int linenumber;
char *usermap;
char *ident_user;
char *pg_role;
regex_t re;
regex_t re;
} IdentLine;
/* kluge to avoid including libpq/libpq-be.h here */

View File

@@ -44,7 +44,7 @@ typedef struct
/*
* prototypes for functions in pqcomm.c
*/
extern int StreamServerPort(int family, char *hostName,
extern int StreamServerPort(int family, char *hostName,
unsigned short portNumber, char *unixSocketDir,
pgsocket ListenSocket[], int MaxListen);
extern int StreamConnection(pgsocket server_fd, Port *port);

View File

@@ -75,7 +75,7 @@ typedef struct
/*
* The maximum workable length of a socket path is what will fit into
* struct sockaddr_un. This is usually only 100 or so bytes :-(.
* struct sockaddr_un. This is usually only 100 or so bytes :-(.
*
* For consistency, always pass a MAXPGPATH-sized buffer to UNIXSOCK_PATH(),
* then complain if the resulting string is >= UNIXSOCK_PATH_BUFLEN bytes.

View File

@@ -45,37 +45,37 @@ typedef unsigned int pg_wchar;
* MULE Internal Encoding (MIC)
*
* This encoding follows the design used within XEmacs; it is meant to
* subsume many externally-defined character sets. Each character includes
* subsume many externally-defined character sets. Each character includes
* identification of the character set it belongs to, so the encoding is
* general but somewhat bulky.
*
* Currently PostgreSQL supports 5 types of MULE character sets:
*
* 1) 1-byte ASCII characters. Each byte is below 0x80.
* 1) 1-byte ASCII characters. Each byte is below 0x80.
*
* 2) "Official" single byte charsets such as ISO-8859-1 (Latin1).
* Each MULE character consists of 2 bytes: LC1 + C1, where LC1 is
* an identifier for the charset (in the range 0x81 to 0x8d) and C1
* is the character code (in the range 0xa0 to 0xff).
* Each MULE character consists of 2 bytes: LC1 + C1, where LC1 is
* an identifier for the charset (in the range 0x81 to 0x8d) and C1
* is the character code (in the range 0xa0 to 0xff).
*
* 3) "Private" single byte charsets such as SISHENG. Each MULE
* character consists of 3 bytes: LCPRV1 + LC12 + C1, where LCPRV1
* is a private-charset flag, LC12 is an identifier for the charset,
* and C1 is the character code (in the range 0xa0 to 0xff).
* LCPRV1 is either 0x9a (if LC12 is in the range 0xa0 to 0xdf)
* or 0x9b (if LC12 is in the range 0xe0 to 0xef).
* character consists of 3 bytes: LCPRV1 + LC12 + C1, where LCPRV1
* is a private-charset flag, LC12 is an identifier for the charset,
* and C1 is the character code (in the range 0xa0 to 0xff).
* LCPRV1 is either 0x9a (if LC12 is in the range 0xa0 to 0xdf)
* or 0x9b (if LC12 is in the range 0xe0 to 0xef).
*
* 4) "Official" multibyte charsets such as JIS X0208. Each MULE
* character consists of 3 bytes: LC2 + C1 + C2, where LC2 is
* an identifier for the charset (in the range 0x90 to 0x99) and C1
* and C2 form the character code (each in the range 0xa0 to 0xff).
* 4) "Official" multibyte charsets such as JIS X0208. Each MULE
* character consists of 3 bytes: LC2 + C1 + C2, where LC2 is
* an identifier for the charset (in the range 0x90 to 0x99) and C1
* and C2 form the character code (each in the range 0xa0 to 0xff).
*
* 5) "Private" multibyte charsets such as CNS 11643-1992 Plane 3.
* Each MULE character consists of 4 bytes: LCPRV2 + LC22 + C1 + C2,
* where LCPRV2 is a private-charset flag, LC22 is an identifier for
* the charset, and C1 and C2 form the character code (each in the range
* 0xa0 to 0xff). LCPRV2 is either 0x9c (if LC22 is in the range 0xf0
* to 0xf4) or 0x9d (if LC22 is in the range 0xf5 to 0xfe).
* Each MULE character consists of 4 bytes: LCPRV2 + LC22 + C1 + C2,
* where LCPRV2 is a private-charset flag, LC22 is an identifier for
* the charset, and C1 and C2 form the character code (each in the range
* 0xa0 to 0xff). LCPRV2 is either 0x9c (if LC22 is in the range 0xf0
* to 0xf4) or 0x9d (if LC22 is in the range 0xf5 to 0xfe).
*
* "Official" encodings are those that have been assigned code numbers by
* the XEmacs project; "private" encodings have Postgres-specific charset
@@ -133,7 +133,8 @@ 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_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) */
@@ -167,44 +168,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) */
@@ -345,8 +346,8 @@ extern pg_enc2gettext pg_enc2gettext_tbl[];
* 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,
@@ -362,10 +363,10 @@ 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 */
mbverifier mbverify; /* verify multibyte sequence */
@@ -523,7 +524,7 @@ extern void check_encoding_conversion_args(int src_encoding,
extern void report_invalid_encoding(int encoding, const char *mbstr, int len) __attribute__((noreturn));
extern void report_untranslatable_char(int src_encoding, int dest_encoding,
const char *mbstr, int len) __attribute__((noreturn));
const char *mbstr, int len) __attribute__((noreturn));
extern void pg_ascii2mic(const unsigned char *l, unsigned char *p, int len);
extern void pg_mic2ascii(const unsigned char *mic, unsigned char *p, int len);

View File

@@ -342,7 +342,7 @@ typedef enum ProcessingMode
extern ProcessingMode Mode;
#define IsBootstrapProcessingMode() (Mode == BootstrapProcessing)
#define IsBootstrapProcessingMode() (Mode == BootstrapProcessing)
#define IsInitProcessingMode() (Mode == InitProcessing)
#define IsNormalProcessingMode() (Mode == NormalProcessing)
@@ -358,7 +358,7 @@ extern ProcessingMode Mode;
/*
* Auxiliary-process type identifiers. These used to be in bootstrap.h
* Auxiliary-process type identifiers. These used to be in bootstrap.h
* but it seems saner to have them here, with the ProcessingMode stuff.
* The MyAuxProcType global is defined and set in bootstrap.c.
*/
@@ -381,7 +381,7 @@ extern AuxProcType MyAuxProcType;
#define AmBootstrapProcess() (MyAuxProcType == BootstrapProcess)
#define AmStartupProcess() (MyAuxProcType == StartupProcess)
#define AmBackgroundWriterProcess() (MyAuxProcType == BgWriterProcess)
#define AmBackgroundWriterProcess() (MyAuxProcType == BgWriterProcess)
#define AmCheckpointerProcess() (MyAuxProcType == CheckpointerProcess)
#define AmWalWriterProcess() (MyAuxProcType == WalWriterProcess)
#define AmWalReceiverProcess() (MyAuxProcType == WalReceiverProcess)

View File

@@ -573,7 +573,7 @@ typedef struct DefElem
/*
* LockingClause - raw representation of FOR [NO KEY] UPDATE/[KEY] SHARE
* options
* options
*
* Note: lockedRels == NIL means "all relations in query". Otherwise it
* is a list of RangeVar nodes. (We use RangeVar mainly because it carries
@@ -1508,7 +1508,8 @@ typedef struct CreateStmt
typedef enum ConstrType /* types of constraints */
{
CONSTR_NULL, /* not standard SQL, but a lot of people expect it */
CONSTR_NULL, /* not standard SQL, but a lot of people
* expect it */
CONSTR_NOTNULL,
CONSTR_DEFAULT,
CONSTR_CHECK,

View File

@@ -327,7 +327,7 @@ typedef enum CoercionContext
* NB: equal() ignores CoercionForm fields, therefore this *must* not carry
* any semantically significant information. We need that behavior so that
* the planner will consider equivalent implicit and explicit casts to be
* equivalent. In cases where those actually behave differently, the coercion
* equivalent. In cases where those actually behave differently, the coercion
* function's arguments will be different.
*/
typedef enum CoercionForm

View File

@@ -195,9 +195,9 @@ typedef struct PlannerInfo
List *full_join_clauses; /* list of RestrictInfos for
* mergejoinable full join clauses */
List *join_info_list; /* list of SpecialJoinInfos */
List *join_info_list; /* list of SpecialJoinInfos */
List *lateral_info_list; /* list of LateralJoinInfos */
List *lateral_info_list; /* list of LateralJoinInfos */
List *append_rel_list; /* list of AppendRelInfos */
@@ -227,7 +227,7 @@ typedef struct PlannerInfo
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 hasLateralRTEs; /* true if any RTEs are marked LATERAL */
bool hasHavingQual; /* true if havingQual was non-null */
bool hasPseudoConstantQuals; /* true if any RestrictInfo has
* pseudoconstant = true */
@@ -411,7 +411,7 @@ typedef struct RelOptInfo
int width; /* estimated avg width of result tuples */
/* per-relation planner control flags */
bool consider_startup; /* keep cheap-startup-cost paths? */
bool consider_startup; /* keep cheap-startup-cost paths? */
/* materialization information */
List *reltargetlist; /* Vars to be output by scan of relation */
@@ -431,7 +431,7 @@ typedef struct RelOptInfo
Relids *attr_needed; /* array indexed [min_attr .. max_attr] */
int32 *attr_widths; /* array indexed [min_attr .. max_attr] */
List *lateral_vars; /* LATERAL Vars and PHVs referenced by rel */
Relids lateral_relids; /* minimum parameterization of rel */
Relids lateral_relids; /* minimum parameterization of rel */
List *indexlist; /* list of IndexOptInfo */
BlockNumber pages; /* size estimates derived from pg_class */
double tuples;
@@ -439,7 +439,7 @@ typedef struct RelOptInfo
/* use "struct Plan" to avoid including plannodes.h here */
struct Plan *subplan; /* if subquery */
PlannerInfo *subroot; /* if subquery */
List *subplan_params; /* if subquery */
List *subplan_params; /* if subquery */
/* use "struct FdwRoutine" to avoid including fdwapi.h here */
struct FdwRoutine *fdwroutine; /* if foreign table */
void *fdw_private; /* if foreign table */
@@ -1531,7 +1531,7 @@ typedef struct MinMaxAggInfo
*
* A Var: the slot represents a variable of this level that must be passed
* down because subqueries have outer references to it, or must be passed
* from a NestLoop node to its inner scan. The varlevelsup value in the Var
* from a NestLoop node to its inner scan. The varlevelsup value in the Var
* will always be zero.
*
* A PlaceHolderVar: this works much like the Var case, except that the

View File

@@ -36,7 +36,7 @@ extern Plan *subquery_planner(PlannerGlobal *glob, Query *parse,
PlannerInfo **subroot);
extern void add_tlist_costs_to_plan(PlannerInfo *root, Plan *plan,
List *tlist);
List *tlist);
extern bool is_dummy_plan(Plan *plan);

View File

@@ -31,38 +31,38 @@
*/
typedef enum ParseExprKind
{
EXPR_KIND_NONE = 0, /* "not in an expression" */
EXPR_KIND_OTHER, /* reserved for extensions */
EXPR_KIND_JOIN_ON, /* JOIN ON */
EXPR_KIND_JOIN_USING, /* JOIN USING */
EXPR_KIND_FROM_SUBSELECT, /* sub-SELECT in FROM clause */
EXPR_KIND_FROM_FUNCTION, /* function in FROM clause */
EXPR_KIND_WHERE, /* WHERE */
EXPR_KIND_HAVING, /* HAVING */
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_NONE = 0, /* "not in an expression" */
EXPR_KIND_OTHER, /* reserved for extensions */
EXPR_KIND_JOIN_ON, /* JOIN ON */
EXPR_KIND_JOIN_USING, /* JOIN USING */
EXPR_KIND_FROM_SUBSELECT, /* sub-SELECT in FROM clause */
EXPR_KIND_FROM_FUNCTION, /* function in FROM clause */
EXPR_KIND_WHERE, /* WHERE */
EXPR_KIND_HAVING, /* HAVING */
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_ROWS, /* window frame clause with ROWS */
EXPR_KIND_SELECT_TARGET, /* SELECT target list item */
EXPR_KIND_INSERT_TARGET, /* INSERT target list item */
EXPR_KIND_UPDATE_SOURCE, /* UPDATE assignment source item */
EXPR_KIND_UPDATE_TARGET, /* UPDATE assignment target item */
EXPR_KIND_GROUP_BY, /* GROUP BY */
EXPR_KIND_ORDER_BY, /* ORDER BY */
EXPR_KIND_DISTINCT_ON, /* DISTINCT ON */
EXPR_KIND_LIMIT, /* LIMIT */
EXPR_KIND_OFFSET, /* OFFSET */
EXPR_KIND_RETURNING, /* RETURNING */
EXPR_KIND_VALUES, /* VALUES */
EXPR_KIND_CHECK_CONSTRAINT, /* CHECK constraint for a table */
EXPR_KIND_DOMAIN_CHECK, /* CHECK constraint for a domain */
EXPR_KIND_COLUMN_DEFAULT, /* default value for a table column */
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_SELECT_TARGET, /* SELECT target list item */
EXPR_KIND_INSERT_TARGET, /* INSERT target list item */
EXPR_KIND_UPDATE_SOURCE, /* UPDATE assignment source item */
EXPR_KIND_UPDATE_TARGET, /* UPDATE assignment target item */
EXPR_KIND_GROUP_BY, /* GROUP BY */
EXPR_KIND_ORDER_BY, /* ORDER BY */
EXPR_KIND_DISTINCT_ON, /* DISTINCT ON */
EXPR_KIND_LIMIT, /* LIMIT */
EXPR_KIND_OFFSET, /* OFFSET */
EXPR_KIND_RETURNING, /* RETURNING */
EXPR_KIND_VALUES, /* VALUES */
EXPR_KIND_CHECK_CONSTRAINT, /* CHECK constraint for a table */
EXPR_KIND_DOMAIN_CHECK, /* CHECK constraint for a domain */
EXPR_KIND_COLUMN_DEFAULT, /* default value for a table column */
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_EXECUTE_PARAMETER, /* parameter value in EXECUTE */
EXPR_KIND_TRIGGER_WHEN /* WHEN condition in CREATE TRIGGER */
EXPR_KIND_TRIGGER_WHEN /* WHEN condition in CREATE TRIGGER */
} ParseExprKind;
@@ -181,8 +181,8 @@ struct ParseState
*
* While processing the FROM clause, namespace items may appear with
* p_lateral_only set, meaning they are visible only to LATERAL
* subexpressions. (The pstate's p_lateral_active flag tells whether we are
* inside such a subexpression at the moment.) If p_lateral_ok is not set,
* subexpressions. (The pstate's p_lateral_active flag tells whether we are
* inside such a subexpression at the moment.) If p_lateral_ok is not set,
* it's an error to actually use such a namespace item. One might think it
* would be better to just exclude such items from visibility, but the wording
* of SQL:2008 requires us to do it this way.
@@ -196,7 +196,7 @@ typedef struct ParseNamespaceItem
{
RangeTblEntry *p_rte; /* The relation's rangetable entry */
bool p_rel_visible; /* Relation name is visible? */
bool p_cols_visible; /* Column names visible as unqualified refs? */
bool p_cols_visible; /* Column names visible as unqualified refs? */
bool p_lateral_only; /* Is only visible to LATERAL expressions? */
bool p_lateral_ok; /* If so, does join type allow use? */
} ParseNamespaceItem;

View File

@@ -86,7 +86,7 @@ extern void addRTEtoQuery(ParseState *pstate, RangeTblEntry *rte,
bool addToRelNameSpace, bool addToVarNameSpace);
extern void errorMissingRTE(ParseState *pstate, RangeVar *relation) __attribute__((noreturn));
extern void errorMissingColumn(ParseState *pstate,
char *relname, char *colname, int location) __attribute__((noreturn));
char *relname, char *colname, int location) __attribute__((noreturn));
extern void expandRTE(RangeTblEntry *rte, int rtindex, int sublevels_up,
int location, bool include_dropped,
List **colnames, List **colvars);

View File

@@ -440,7 +440,7 @@ extern int pqGethostbyname(const char *name,
extern void pg_qsort(void *base, size_t nel, size_t elsize,
int (*cmp) (const void *, const void *));
extern int pg_qsort_strcmp(const void *a, const void *b);
extern int pg_qsort_strcmp(const void *a, const void *b);
#define qsort(a,b,c,d) pg_qsort(a,b,c,d)

View File

@@ -71,7 +71,7 @@
* http://msdn.microsoft.com/en-us/library/8fskxacy(v=vs.80).aspx
* http://msdn.microsoft.com/en-us/library/a90k134d(v=vs.80).aspx
*/
#if defined(WIN32) || defined(__CYGWIN__)
#ifdef BUILDING_DLL

View File

@@ -458,7 +458,7 @@ typedef Datum *DatumPtr;
/*
* MultiXactIdGetDatum
* Returns datum representation for a multixact identifier.
* Returns datum representation for a multixact identifier.
*/
#define MultiXactIdGetDatum(X) ((Datum) SET_4_BYTES((X)))

View File

@@ -1,14 +1,14 @@
/*--------------------------------------------------------------------
* bgworker.h
* POSTGRES pluggable background workers interface
* POSTGRES pluggable background workers interface
*
* A background worker is a process able to run arbitrary, user-supplied code,
* including normal transactions.
*
* Any external module loaded via shared_preload_libraries can register a
* worker. Then, at the appropriate time, the worker process is forked from
* worker. Then, at the appropriate time, the worker process is forked from
* the postmaster and runs the user-supplied "main" function. This code may
* connect to a database and run transactions. Once started, it stays active
* connect to a database and run transactions. Once started, it stays active
* until shutdown or crash. The process should sleep during periods of
* inactivity.
*
@@ -28,7 +28,7 @@
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
* src/include/postmaster/bgworker.h
* src/include/postmaster/bgworker.h
*--------------------------------------------------------------------
*/
#ifndef BGWORKER_H
@@ -52,8 +52,8 @@
#define BGWORKER_BACKEND_DATABASE_CONNECTION 0x0002
typedef void (*bgworker_main_type)(void *main_arg);
typedef void (*bgworker_sighdlr_type)(SIGNAL_ARGS);
typedef void (*bgworker_main_type) (void *main_arg);
typedef void (*bgworker_sighdlr_type) (SIGNAL_ARGS);
/*
* Points in time at which a bgworker can request to be started
@@ -71,10 +71,10 @@ typedef enum
typedef struct BackgroundWorker
{
char *bgw_name;
int bgw_flags;
int bgw_flags;
BgWorkerStartTime bgw_start_time;
int bgw_restart_time; /* in seconds, or BGW_NEVER_RESTART */
bgworker_main_type bgw_main;
bgworker_main_type bgw_main;
void *bgw_main_arg;
bgworker_sighdlr_type bgw_sighup;
bgworker_sighdlr_type bgw_sigterm;
@@ -101,4 +101,4 @@ extern void BackgroundWorkerInitializeConnection(char *dbname, char *username);
extern void BackgroundWorkerBlockSignals(void);
extern void BackgroundWorkerUnblockSignals(void);
#endif /* BGWORKER_H */
#endif /* BGWORKER_H */

View File

@@ -51,11 +51,11 @@ extern void ClosePostmasterPorts(bool am_syslogger);
extern int MaxLivePostmasterChildren(void);
extern int GetNumShmemAttachedBgworkers(void);
extern int GetNumShmemAttachedBgworkers(void);
#ifdef EXEC_BACKEND
extern pid_t postmaster_forkexec(int argc, char *argv[]);
extern void SubPostmasterMain(int argc, char *argv[]) __attribute__((noreturn));
extern void SubPostmasterMain(int argc, char *argv[]) __attribute__((noreturn));
extern Size ShmemBackendArraySize(void);
extern void ShmemBackendArrayAllocation(void);

View File

@@ -60,17 +60,17 @@ typedef struct
pg_time_t startTime;
/*
* receiveStart and receiveStartTLI indicate the first byte position
* and timeline that will be received. When startup process starts the
* walreceiver, it sets these to the point where it wants the streaming
* to begin.
* receiveStart and receiveStartTLI indicate the first byte position and
* timeline that will be received. When startup process starts the
* walreceiver, it sets these to the point where it wants the streaming to
* begin.
*/
XLogRecPtr receiveStart;
TimeLineID receiveStartTLI;
/*
* receivedUpto-1 is the last byte position that has already been
* received, and receivedTLI is the timeline it came from. At the first
* received, and receivedTLI is the timeline it came from. At the first
* startup of walreceiver, these are set to receiveStart and
* receiveStartTLI. After that, walreceiver updates these whenever it
* flushes the received WAL to disk.

View File

@@ -22,7 +22,7 @@
#define RULE_FIRES_ON_REPLICA 'R'
#define RULE_DISABLED 'D'
extern Oid DefineRule(RuleStmt *stmt, const char *queryString);
extern Oid DefineRule(RuleStmt *stmt, const char *queryString);
extern Oid DefineQueryRewrite(char *rulename,
Oid event_relid,

View File

@@ -35,7 +35,7 @@ typedef enum ReplaceVarsNoMatchOption
{
REPLACEVARS_REPORT_ERROR, /* throw error if no match */
REPLACEVARS_CHANGE_VARNO, /* change the Var's varno, nothing else */
REPLACEVARS_SUBSTITUTE_NULL /* replace with a NULL Const */
REPLACEVARS_SUBSTITUTE_NULL /* replace with a NULL Const */
} ReplaceVarsNoMatchOption;

View File

@@ -96,7 +96,7 @@ typedef struct
#define PageXLogRecPtrGet(val) \
((uint64) (val).xlogid << 32 | (val).xrecoff)
#define PageXLogRecPtrSet(ptr, lsn) \
((ptr).xlogid = (uint32) ((lsn) >> 32), (ptr).xrecoff = (uint32) (lsn))
((ptr).xlogid = (uint32) ((lsn) >> 32), (ptr).xrecoff = (uint32) (lsn))
/*
* disk page organization
@@ -104,7 +104,7 @@ typedef struct
* space management information generic to any page
*
* pd_lsn - identifies xlog record for last change to this page.
* pd_checksum - page checksum, if set.
* pd_checksum - page checksum, if set.
* pd_flags - flag bits.
* pd_lower - offset to start of free space.
* pd_upper - offset to end of free space.
@@ -147,7 +147,7 @@ typedef struct
typedef struct PageHeaderData
{
/* XXX LSN is member of *any* block, not only page-organized ones */
PageXLogRecPtr pd_lsn; /* LSN: next byte after last byte of xlog
PageXLogRecPtr pd_lsn; /* LSN: next byte after last byte of xlog
* record for last change to this page */
uint16 pd_checksum; /* checksum */
uint16 pd_flags; /* flag bits, see below */

View File

@@ -70,7 +70,7 @@ typedef struct LargeObjectDesc
#define LOBLKSIZE (BLCKSZ / 4)
/*
* Maximum length in bytes for a large object. To make this larger, we'd
* Maximum length in bytes for a large object. To make this larger, we'd
* have to widen pg_largeobject.pageno as well as various internal variables.
*/
#define MAX_LARGE_OBJECT_SIZE ((int64) INT_MAX * LOBLKSIZE)

View File

@@ -486,5 +486,4 @@ typedef struct TwoPhasePredicateRecord
*/
extern PredicateLockData *GetPredicateLockStatusData(void);
#endif /* PREDICATE_INTERNALS_H */

View File

@@ -70,7 +70,7 @@ typedef enum ForkNumber
* is a "mapped" relation, whose current true filenode number is available
* from relmapper.c. Again, this case is NOT allowed in RelFileNodes.
*
* Note: various places use RelFileNode in hashtable keys. Therefore,
* Note: various places use RelFileNode in hashtable keys. Therefore,
* there *must not* be any unused padding bytes in this struct. That
* should be safe as long as all the fields are of type Oid.
*/
@@ -83,7 +83,7 @@ typedef struct RelFileNode
/*
* Augmenting a relfilenode with the backend ID provides all the information
* we need to locate the physical storage. The backend ID is InvalidBackendId
* we need to locate the physical storage. The backend ID is InvalidBackendId
* for regular relations (those accessible to more than one backend), or the
* owning backend's ID for backend-local relations. Backend-local relations
* are always transient and removed in case of a database crash; they are

View File

@@ -68,7 +68,7 @@ typedef struct xl_standby_locks
typedef struct xl_running_xacts
{
int xcnt; /* # of xact ids in xids[] */
int subxcnt; /* # of subxact ids in xids[] */
int subxcnt; /* # of subxact ids in xids[] */
bool subxid_overflow; /* snapshot overflowed, subxids missing */
TransactionId nextXid; /* copy of ShmemVariableCache->nextXid */
TransactionId oldestRunningXid; /* *not* oldestXmin */
@@ -99,7 +99,7 @@ extern void standby_desc(StringInfo buf, uint8 xl_info, char *rec);
typedef struct RunningTransactionsData
{
int xcnt; /* # of xact ids in xids[] */
int subxcnt; /* # of subxact ids in xids[] */
int subxcnt; /* # of subxact ids in xids[] */
bool subxid_overflow; /* snapshot overflowed, subxids missing */
TransactionId nextXid; /* copy of ShmemVariableCache->nextXid */
TransactionId oldestRunningXid; /* *not* oldestXmin */

View File

@@ -18,16 +18,16 @@
typedef enum
{
PROCESS_UTILITY_TOPLEVEL, /* toplevel interactive command */
PROCESS_UTILITY_QUERY, /* a complete query, but not toplevel */
PROCESS_UTILITY_SUBCOMMAND /* a portion of a query */
PROCESS_UTILITY_TOPLEVEL, /* toplevel interactive command */
PROCESS_UTILITY_QUERY, /* a complete query, but not toplevel */
PROCESS_UTILITY_SUBCOMMAND /* a portion of a query */
} ProcessUtilityContext;
/* Hook for plugins to get control in ProcessUtility() */
typedef void (*ProcessUtility_hook_type) (Node *parsetree,
const char *queryString, ProcessUtilityContext context,
ParamListInfo params,
DestReceiver *dest, char *completionTag);
const char *queryString, ProcessUtilityContext context,
ParamListInfo params,
DestReceiver *dest, char *completionTag);
extern PGDLLIMPORT ProcessUtility_hook_type ProcessUtility_hook;
extern void ProcessUtility(Node *parsetree, const char *queryString,

View File

@@ -576,7 +576,7 @@ extern Datum regexp_split_to_table_no_flags(PG_FUNCTION_ARGS);
extern Datum regexp_split_to_array(PG_FUNCTION_ARGS);
extern Datum regexp_split_to_array_no_flags(PG_FUNCTION_ARGS);
extern char *regexp_fixed_prefix(text *text_re, bool case_insensitive,
Oid collation, bool *exact);
Oid collation, bool *exact);
/* regproc.c */
extern Datum regprocin(PG_FUNCTION_ARGS);

View File

@@ -118,7 +118,7 @@
if (__builtin_constant_p(elevel) && (elevel) >= ERROR) \
pg_unreachable(); \
} while(0)
#else /* !HAVE__BUILTIN_CONSTANT_P */
#else /* !HAVE__BUILTIN_CONSTANT_P */
#define ereport_domain(elevel, domain, rest) \
do { \
const int elevel_ = (elevel); \
@@ -127,7 +127,7 @@
if (elevel_ >= ERROR) \
pg_unreachable(); \
} while(0)
#endif /* HAVE__BUILTIN_CONSTANT_P */
#endif /* HAVE__BUILTIN_CONSTANT_P */
#define ereport(elevel, rest) \
ereport_domain(elevel, TEXTDOMAIN, rest)
@@ -203,7 +203,7 @@ __attribute__((format(PG_PRINTF_ATTRIBUTE, 1, 2)));
* set_errcontext_domain() first sets the domain to be used, and
* errcontext_msg() passes the actual message.
*/
#define errcontext set_errcontext_domain(TEXTDOMAIN), errcontext_msg
#define errcontext set_errcontext_domain(TEXTDOMAIN), errcontext_msg
extern int set_errcontext_domain(const char *domain);
extern int
@@ -247,7 +247,7 @@ extern int getinternalerrposition(void);
if (__builtin_constant_p(elevel) && (elevel) >= ERROR) \
pg_unreachable(); \
} while(0)
#else /* !HAVE__BUILTIN_CONSTANT_P */
#else /* !HAVE__BUILTIN_CONSTANT_P */
#define elog(elevel, ...) \
do { \
int elevel_; \
@@ -257,12 +257,12 @@ extern int getinternalerrposition(void);
if (elevel_ >= ERROR) \
pg_unreachable(); \
} while(0)
#endif /* HAVE__BUILTIN_CONSTANT_P */
#else /* !HAVE__VA_ARGS */
#endif /* HAVE__BUILTIN_CONSTANT_P */
#else /* !HAVE__VA_ARGS */
#define elog \
elog_start(__FILE__, __LINE__, PG_FUNCNAME_MACRO), \
elog_finish
#endif /* HAVE__VA_ARGS */
#endif /* HAVE__VA_ARGS */
extern void elog_start(const char *filename, int lineno, const char *funcname);
extern void
@@ -381,7 +381,7 @@ typedef struct ErrorData
int lineno; /* __LINE__ of ereport() call */
const char *funcname; /* __func__ of ereport() call */
const char *domain; /* message domain */
const char *context_domain; /* message domain for context message */
const char *context_domain; /* message domain for context message */
int sqlerrcode; /* encoded ERRSTATE */
char *message; /* primary error message */
char *detail; /* detail error message */

View File

@@ -25,10 +25,10 @@ typedef enum
typedef struct
{
Oid fnoid; /* function to be called */
char enabled; /* as SESSION_REPLICATION_ROLE_* */
int ntags; /* number of command tags */
char **tag; /* command tags in SORTED order */
Oid fnoid; /* function to be called */
char enabled; /* as SESSION_REPLICATION_ROLE_* */
int ntags; /* number of command tags */
char **tag; /* command tags in SORTED order */
} EventTriggerCacheItem;
extern List *EventCacheLookup(EventTriggerEvent event);

View File

@@ -261,5 +261,4 @@ extern const char *config_enum_lookup_by_value(struct config_enum * record, int
extern bool config_enum_lookup_by_name(struct config_enum * record,
const char *value, int *retval);
#endif /* GUC_TABLES_H */

View File

@@ -31,7 +31,7 @@ typedef enum
JSON_TOKEN_FALSE,
JSON_TOKEN_NULL,
JSON_TOKEN_END,
} JsonTokenType;
} JsonTokenType;
/*
@@ -86,7 +86,8 @@ typedef struct jsonSemAction
json_aelem_action array_element_start;
json_aelem_action array_element_end;
json_scalar_action scalar;
} jsonSemAction, *JsonSemAction;
} jsonSemAction,
*JsonSemAction;
/*
* parse_json will parse the string in the lex calling the

View File

@@ -89,7 +89,7 @@ MemoryContextSwitchTo(MemoryContext context)
* allocated in a context, not with malloc().
*/
extern char *MemoryContextStrdup(MemoryContext context, const char *string);
#endif /* !FRONTEND */
#endif /* !FRONTEND */
extern char *pstrdup(const char *in);
extern char *pnstrdup(const char *in, Size len);

View File

@@ -61,11 +61,11 @@
* allows the query tree to be discarded easily when it is invalidated.
*
* Some callers wish to use the CachedPlan API even with one-shot queries
* that have no reason to be saved at all. We therefore support a "oneshot"
* variant that does no data copying or invalidation checking. In this case
* that have no reason to be saved at all. We therefore support a "oneshot"
* variant that does no data copying or invalidation checking. In this case
* there are no separate memory contexts: the CachedPlanSource struct and
* all subsidiary data live in the caller's CurrentMemoryContext, and there
* is no way to free memory short of clearing that entire context. A oneshot
* is no way to free memory short of clearing that entire context. A oneshot
* plan is always treated as unsaved.
*
* Note: the string referenced by commandTag is not subsidiary storage;
@@ -143,8 +143,8 @@ extern CachedPlanSource *CreateCachedPlan(Node *raw_parse_tree,
const char *query_string,
const char *commandTag);
extern CachedPlanSource *CreateOneShotCachedPlan(Node *raw_parse_tree,
const char *query_string,
const char *commandTag);
const char *query_string,
const char *commandTag);
extern void CompleteCachedPlan(CachedPlanSource *plansource,
List *querytree_list,
MemoryContext querytree_context,

View File

@@ -84,20 +84,15 @@ typedef struct RelationData
/*
* rd_createSubid is the ID of the highest subtransaction the rel has
* survived into; or zero if the rel was not created in the current top
* transaction. This can be now be relied on, whereas previously it
* could be "forgotten" in earlier releases.
* Likewise, rd_newRelfilenodeSubid is the ID of the highest
* subtransaction the relfilenode change has survived into, or zero if not
* changed in the current transaction (or we have forgotten changing it).
* rd_newRelfilenodeSubid can be forgotten when a relation has multiple
* new relfilenodes within a single transaction, with one of them occuring
* in a subsequently aborted subtransaction, e.g.
* BEGIN;
* TRUNCATE t;
* SAVEPOINT save;
* TRUNCATE t;
* ROLLBACK TO save;
* -- rd_newRelfilenode is now forgotten
* transaction. This can be now be relied on, whereas previously it could
* be "forgotten" in earlier releases. Likewise, rd_newRelfilenodeSubid is
* the ID of the highest subtransaction the relfilenode change has
* survived into, or zero if not changed in the current transaction (or we
* have forgotten changing it). rd_newRelfilenodeSubid can be forgotten
* when a relation has multiple new relfilenodes within a single
* transaction, with one of them occuring in a subsequently aborted
* subtransaction, e.g. BEGIN; TRUNCATE t; SAVEPOINT save; TRUNCATE t;
* ROLLBACK TO save; -- rd_newRelfilenode is now forgotten
*/
SubTransactionId rd_createSubid; /* rel was created in current xact */
SubTransactionId rd_newRelfilenodeSubid; /* new relfilenode assigned in
@@ -162,7 +157,7 @@ typedef struct RelationData
* foreign-table support
*
* rd_fdwroutine must point to a single memory chunk palloc'd in
* CacheMemoryContext. It will be freed and reset to NULL on a relcache
* CacheMemoryContext. It will be freed and reset to NULL on a relcache
* reset.
*/
@@ -403,15 +398,15 @@ typedef struct StdRdOptions
/*
* RelationIsScannable
* Currently can only be false for a materialized view which has not been
* populated by its query. This is likely to get more complicated later,
* so use a macro which looks like a function.
* Currently can only be false for a materialized view which has not been
* populated by its query. This is likely to get more complicated later,
* so use a macro which looks like a function.
*/
#define RelationIsScannable(relation) ((relation)->rd_rel->relispopulated)
/*
* RelationIsPopulated
* Currently, we don't physically distinguish the "populated" and
* Currently, we don't physically distinguish the "populated" and
* "scannable" properties of matviews, but that may change later.
* Hence, use the appropriate one of these macros in code tests.
*/

View File

@@ -70,5 +70,4 @@ typedef struct TriggerDesc
bool trig_truncate_after_statement;
} TriggerDesc;
#endif /* RELTRIGGER_H */