PostgreSQL Source Code  git master
readfuncs.c File Reference
#include "postgres.h"
#include <math.h>
#include "fmgr.h"
#include "miscadmin.h"
#include "nodes/extensible.h"
#include "nodes/parsenodes.h"
#include "nodes/plannodes.h"
#include "nodes/readfuncs.h"
#include "utils/builtins.h"
Include dependency graph for readfuncs.c:

Go to the source code of this file.

Macros

#define READ_LOCALS_NO_FIELDS(nodeTypeName)   nodeTypeName *local_node = makeNode(nodeTypeName)
 
#define READ_TEMP_LOCALS()
 
#define READ_LOCALS(nodeTypeName)
 
#define READ_INT_FIELD(fldname)
 
#define READ_UINT_FIELD(fldname)
 
#define READ_UINT64_FIELD(fldname)
 
#define READ_LONG_FIELD(fldname)
 
#define READ_OID_FIELD(fldname)
 
#define READ_CHAR_FIELD(fldname)
 
#define READ_ENUM_FIELD(fldname, enumtype)
 
#define READ_FLOAT_FIELD(fldname)
 
#define READ_BOOL_FIELD(fldname)
 
#define READ_STRING_FIELD(fldname)
 
#define READ_LOCATION_FIELD(fldname)
 
#define READ_NODE_FIELD(fldname)
 
#define READ_BITMAPSET_FIELD(fldname)
 
#define READ_ATTRNUMBER_ARRAY(fldname, len)
 
#define READ_OID_ARRAY(fldname, len)
 
#define READ_INT_ARRAY(fldname, len)
 
#define READ_BOOL_ARRAY(fldname, len)
 
#define READ_DONE()   return local_node
 
#define atoui(x)   ((unsigned int) strtoul((x), NULL, 10))
 
#define strtobool(x)   ((*(x) == 't') ? true : false)
 
#define nullable_string(token, length)   ((length) == 0 ? NULL : debackslash(token, length))
 
#define MATCH(tokname, namelen)   (length == namelen && memcmp(token, tokname, namelen) == 0)
 

Functions

static Bitmapset_readBitmapset (void)
 
BitmapsetreadBitmapset (void)
 
static Query_readQuery (void)
 
static NotifyStmt_readNotifyStmt (void)
 
static DeclareCursorStmt_readDeclareCursorStmt (void)
 
static WithCheckOption_readWithCheckOption (void)
 
static SortGroupClause_readSortGroupClause (void)
 
static GroupingSet_readGroupingSet (void)
 
static WindowClause_readWindowClause (void)
 
static RowMarkClause_readRowMarkClause (void)
 
static CommonTableExpr_readCommonTableExpr (void)
 
static SetOperationStmt_readSetOperationStmt (void)
 
static Alias_readAlias (void)
 
static RangeVar_readRangeVar (void)
 
static TableFunc_readTableFunc (void)
 
static IntoClause_readIntoClause (void)
 
static Var_readVar (void)
 
static Const_readConst (void)
 
static Param_readParam (void)
 
static Aggref_readAggref (void)
 
static GroupingFunc_readGroupingFunc (void)
 
static WindowFunc_readWindowFunc (void)
 
static SubscriptingRef_readSubscriptingRef (void)
 
static FuncExpr_readFuncExpr (void)
 
static NamedArgExpr_readNamedArgExpr (void)
 
static OpExpr_readOpExpr (void)
 
static DistinctExpr_readDistinctExpr (void)
 
static NullIfExpr_readNullIfExpr (void)
 
static ScalarArrayOpExpr_readScalarArrayOpExpr (void)
 
static BoolExpr_readBoolExpr (void)
 
static SubLink_readSubLink (void)
 
static FieldSelect_readFieldSelect (void)
 
static FieldStore_readFieldStore (void)
 
static RelabelType_readRelabelType (void)
 
static CoerceViaIO_readCoerceViaIO (void)
 
static ArrayCoerceExpr_readArrayCoerceExpr (void)
 
static ConvertRowtypeExpr_readConvertRowtypeExpr (void)
 
static CollateExpr_readCollateExpr (void)
 
static CaseExpr_readCaseExpr (void)
 
static CaseWhen_readCaseWhen (void)
 
static CaseTestExpr_readCaseTestExpr (void)
 
static ArrayExpr_readArrayExpr (void)
 
static RowExpr_readRowExpr (void)
 
static RowCompareExpr_readRowCompareExpr (void)
 
static CoalesceExpr_readCoalesceExpr (void)
 
static MinMaxExpr_readMinMaxExpr (void)
 
static SQLValueFunction_readSQLValueFunction (void)
 
static XmlExpr_readXmlExpr (void)
 
static NullTest_readNullTest (void)
 
static BooleanTest_readBooleanTest (void)
 
static CoerceToDomain_readCoerceToDomain (void)
 
static CoerceToDomainValue_readCoerceToDomainValue (void)
 
static SetToDefault_readSetToDefault (void)
 
static CurrentOfExpr_readCurrentOfExpr (void)
 
static NextValueExpr_readNextValueExpr (void)
 
static InferenceElem_readInferenceElem (void)
 
static TargetEntry_readTargetEntry (void)
 
static RangeTblRef_readRangeTblRef (void)
 
static JoinExpr_readJoinExpr (void)
 
static FromExpr_readFromExpr (void)
 
static OnConflictExpr_readOnConflictExpr (void)
 
static RangeTblEntry_readRangeTblEntry (void)
 
static RangeTblFunction_readRangeTblFunction (void)
 
static TableSampleClause_readTableSampleClause (void)
 
static DefElem_readDefElem (void)
 
static PlannedStmt_readPlannedStmt (void)
 
static void ReadCommonPlan (Plan *local_node)
 
static Plan_readPlan (void)
 
static Result_readResult (void)
 
static ProjectSet_readProjectSet (void)
 
static ModifyTable_readModifyTable (void)
 
static Append_readAppend (void)
 
static MergeAppend_readMergeAppend (void)
 
static RecursiveUnion_readRecursiveUnion (void)
 
static BitmapAnd_readBitmapAnd (void)
 
static BitmapOr_readBitmapOr (void)
 
static void ReadCommonScan (Scan *local_node)
 
static Scan_readScan (void)
 
static SeqScan_readSeqScan (void)
 
static SampleScan_readSampleScan (void)
 
static IndexScan_readIndexScan (void)
 
static IndexOnlyScan_readIndexOnlyScan (void)
 
static BitmapIndexScan_readBitmapIndexScan (void)
 
static BitmapHeapScan_readBitmapHeapScan (void)
 
static TidScan_readTidScan (void)
 
static SubqueryScan_readSubqueryScan (void)
 
static FunctionScan_readFunctionScan (void)
 
static ValuesScan_readValuesScan (void)
 
static TableFuncScan_readTableFuncScan (void)
 
static CteScan_readCteScan (void)
 
static NamedTuplestoreScan_readNamedTuplestoreScan (void)
 
static WorkTableScan_readWorkTableScan (void)
 
static ForeignScan_readForeignScan (void)
 
static CustomScan_readCustomScan (void)
 
static void ReadCommonJoin (Join *local_node)
 
static Join_readJoin (void)
 
static NestLoop_readNestLoop (void)
 
static MergeJoin_readMergeJoin (void)
 
static HashJoin_readHashJoin (void)
 
static Material_readMaterial (void)
 
static Sort_readSort (void)
 
static Group_readGroup (void)
 
static Agg_readAgg (void)
 
static WindowAgg_readWindowAgg (void)
 
static Unique_readUnique (void)
 
static Gather_readGather (void)
 
static GatherMerge_readGatherMerge (void)
 
static Hash_readHash (void)
 
static SetOp_readSetOp (void)
 
static LockRows_readLockRows (void)
 
static Limit_readLimit (void)
 
static NestLoopParam_readNestLoopParam (void)
 
static PlanRowMark_readPlanRowMark (void)
 
static PartitionPruneInfo_readPartitionPruneInfo (void)
 
static PartitionedRelPruneInfo_readPartitionedRelPruneInfo (void)
 
static PartitionPruneStepOp_readPartitionPruneStepOp (void)
 
static PartitionPruneStepCombine_readPartitionPruneStepCombine (void)
 
static PlanInvalItem_readPlanInvalItem (void)
 
static SubPlan_readSubPlan (void)
 
static AlternativeSubPlan_readAlternativeSubPlan (void)
 
static ExtensibleNode_readExtensibleNode (void)
 
static PartitionBoundSpec_readPartitionBoundSpec (void)
 
static PartitionRangeDatum_readPartitionRangeDatum (void)
 
NodeparseNodeString (void)
 
Datum readDatum (bool typbyval)
 
AttrNumberreadAttrNumberCols (int numCols)
 
OidreadOidCols (int numCols)
 
int * readIntCols (int numCols)
 
boolreadBoolCols (int numCols)
 

Macro Definition Documentation

◆ atoui

#define atoui (   x)    ((unsigned int) strtoul((x), NULL, 10))

Definition at line 185 of file readfuncs.c.

Referenced by readDatum().

◆ MATCH

#define MATCH (   tokname,
  namelen 
)    (length == namelen && memcmp(token, tokname, namelen) == 0)

Referenced by parseNodeString().

◆ nullable_string

#define nullable_string (   token,
  length 
)    ((length) == 0 ? NULL : debackslash(token, length))

Definition at line 189 of file readfuncs.c.

Referenced by _readCustomScan(), and _readExtensibleNode().

◆ READ_ATTRNUMBER_ARRAY

#define READ_ATTRNUMBER_ARRAY (   fldname,
  len 
)
Value:
token = pg_strtok(&length); /* skip :fldname */ \
local_node->fldname = readAttrNumberCols(len);
AttrNumber * readAttrNumberCols(int numCols)
Definition: readfuncs.c:2887
const char * pg_strtok(int *length)
Definition: read.c:152

Definition at line 155 of file readfuncs.c.

Referenced by _readAgg(), _readGatherMerge(), _readGroup(), _readMergeAppend(), _readRecursiveUnion(), _readSetOp(), _readSort(), _readUnique(), and _readWindowAgg().

◆ READ_BITMAPSET_FIELD

#define READ_BITMAPSET_FIELD (   fldname)
Value:
token = pg_strtok(&length); /* skip :fldname */ \
(void) token; /* in case not used elsewhere */ \
local_node->fldname = _readBitmapset()
const char * pg_strtok(int *length)
Definition: read.c:152
static Bitmapset * _readBitmapset(void)
Definition: readfuncs.c:197

Definition at line 149 of file readfuncs.c.

Referenced by _readAgg(), _readCustomScan(), _readForeignScan(), _readGather(), _readGatherMerge(), _readModifyTable(), _readPartitionedRelPruneInfo(), _readPartitionPruneInfo(), _readPartitionPruneStepOp(), _readPlannedStmt(), _readRangeTblEntry(), _readRangeTblFunction(), _readTableFunc(), and ReadCommonPlan().

◆ READ_BOOL_ARRAY

#define READ_BOOL_ARRAY (   fldname,
  len 
)
Value:
token = pg_strtok(&length); /* skip :fldname */ \
local_node->fldname = readBoolCols(len);
bool * readBoolCols(int numCols)
Definition: readfuncs.c:2959
const char * pg_strtok(int *length)
Definition: read.c:152

Definition at line 170 of file readfuncs.c.

Referenced by _readGatherMerge(), _readMergeAppend(), _readMergeJoin(), and _readSort().

◆ READ_BOOL_FIELD

◆ READ_CHAR_FIELD

#define READ_CHAR_FIELD (   fldname)
Value:
token = pg_strtok(&length); /* skip :fldname */ \
token = pg_strtok(&length); /* get field value */ \
/* avoid overhead of calling debackslash() for one char */ \
local_node->fldname = (length == 0) ? '\0' : (token[0] == '\\' ? token[1] : token[0])
const char * pg_strtok(int *length)
Definition: read.c:152

Definition at line 98 of file readfuncs.c.

Referenced by _readAggref(), _readPartitionBoundSpec(), _readRangeTblEntry(), and _readRangeVar().

◆ READ_DONE

#define READ_DONE ( )    return local_node

Definition at line 175 of file readfuncs.c.

Referenced by _readAgg(), _readAggref(), _readAlias(), _readAlternativeSubPlan(), _readAppend(), _readArrayCoerceExpr(), _readArrayExpr(), _readBitmapAnd(), _readBitmapHeapScan(), _readBitmapIndexScan(), _readBitmapOr(), _readBooleanTest(), _readBoolExpr(), _readCaseExpr(), _readCaseTestExpr(), _readCaseWhen(), _readCoalesceExpr(), _readCoerceToDomain(), _readCoerceToDomainValue(), _readCoerceViaIO(), _readCollateExpr(), _readCommonTableExpr(), _readConst(), _readConvertRowtypeExpr(), _readCteScan(), _readCurrentOfExpr(), _readCustomScan(), _readDeclareCursorStmt(), _readDefElem(), _readDistinctExpr(), _readExtensibleNode(), _readFieldSelect(), _readFieldStore(), _readForeignScan(), _readFromExpr(), _readFuncExpr(), _readFunctionScan(), _readGather(), _readGatherMerge(), _readGroup(), _readGroupingFunc(), _readGroupingSet(), _readHash(), _readHashJoin(), _readIndexOnlyScan(), _readIndexScan(), _readInferenceElem(), _readIntoClause(), _readJoin(), _readJoinExpr(), _readLimit(), _readLockRows(), _readMaterial(), _readMergeAppend(), _readMergeJoin(), _readMinMaxExpr(), _readModifyTable(), _readNamedArgExpr(), _readNamedTuplestoreScan(), _readNestLoop(), _readNestLoopParam(), _readNextValueExpr(), _readNotifyStmt(), _readNullIfExpr(), _readNullTest(), _readOnConflictExpr(), _readOpExpr(), _readParam(), _readPartitionBoundSpec(), _readPartitionedRelPruneInfo(), _readPartitionPruneInfo(), _readPartitionPruneStepCombine(), _readPartitionPruneStepOp(), _readPartitionRangeDatum(), _readPlan(), _readPlanInvalItem(), _readPlannedStmt(), _readPlanRowMark(), _readProjectSet(), _readQuery(), _readRangeTblEntry(), _readRangeTblFunction(), _readRangeTblRef(), _readRangeVar(), _readRecursiveUnion(), _readRelabelType(), _readResult(), _readRowCompareExpr(), _readRowExpr(), _readRowMarkClause(), _readSampleScan(), _readScalarArrayOpExpr(), _readScan(), _readSeqScan(), _readSetOp(), _readSetOperationStmt(), _readSetToDefault(), _readSort(), _readSortGroupClause(), _readSQLValueFunction(), _readSubLink(), _readSubPlan(), _readSubqueryScan(), _readSubscriptingRef(), _readTableFunc(), _readTableFuncScan(), _readTableSampleClause(), _readTargetEntry(), _readTidScan(), _readUnique(), _readValuesScan(), _readVar(), _readWindowAgg(), _readWindowClause(), _readWindowFunc(), _readWithCheckOption(), _readWorkTableScan(), and _readXmlExpr().

◆ READ_ENUM_FIELD

◆ READ_FLOAT_FIELD

#define READ_FLOAT_FIELD (   fldname)
Value:
token = pg_strtok(&length); /* skip :fldname */ \
token = pg_strtok(&length); /* get field value */ \
local_node->fldname = atof(token)
const char * pg_strtok(int *length)
Definition: read.c:152

Definition at line 111 of file readfuncs.c.

Referenced by _readHash(), _readRangeTblEntry(), _readSubPlan(), and ReadCommonPlan().

◆ READ_INT_ARRAY

#define READ_INT_ARRAY (   fldname,
  len 
)
Value:
token = pg_strtok(&length); /* skip :fldname */ \
local_node->fldname = readIntCols(len);
int * readIntCols(int numCols)
Definition: readfuncs.c:2935
const char * pg_strtok(int *length)
Definition: read.c:152

Definition at line 165 of file readfuncs.c.

Referenced by _readMergeJoin(), and _readPartitionedRelPruneInfo().

◆ READ_INT_FIELD

◆ READ_LOCALS

#define READ_LOCALS (   nodeTypeName)
Value:
READ_LOCALS_NO_FIELDS(nodeTypeName); \
READ_TEMP_LOCALS()
#define READ_LOCALS_NO_FIELDS(nodeTypeName)
Definition: readfuncs.c:54

Definition at line 63 of file readfuncs.c.

Referenced by _readAgg(), _readAggref(), _readAlias(), _readAlternativeSubPlan(), _readAppend(), _readArrayCoerceExpr(), _readArrayExpr(), _readBitmapAnd(), _readBitmapHeapScan(), _readBitmapIndexScan(), _readBitmapOr(), _readBooleanTest(), _readBoolExpr(), _readCaseExpr(), _readCaseTestExpr(), _readCaseWhen(), _readCoalesceExpr(), _readCoerceToDomain(), _readCoerceToDomainValue(), _readCoerceViaIO(), _readCollateExpr(), _readCommonTableExpr(), _readConst(), _readConvertRowtypeExpr(), _readCteScan(), _readCurrentOfExpr(), _readCustomScan(), _readDeclareCursorStmt(), _readDefElem(), _readDistinctExpr(), _readFieldSelect(), _readFieldStore(), _readForeignScan(), _readFromExpr(), _readFuncExpr(), _readFunctionScan(), _readGather(), _readGatherMerge(), _readGroup(), _readGroupingFunc(), _readGroupingSet(), _readHash(), _readHashJoin(), _readIndexOnlyScan(), _readIndexScan(), _readInferenceElem(), _readIntoClause(), _readJoinExpr(), _readLimit(), _readLockRows(), _readMergeAppend(), _readMergeJoin(), _readMinMaxExpr(), _readModifyTable(), _readNamedArgExpr(), _readNamedTuplestoreScan(), _readNestLoop(), _readNestLoopParam(), _readNextValueExpr(), _readNotifyStmt(), _readNullIfExpr(), _readNullTest(), _readOnConflictExpr(), _readOpExpr(), _readParam(), _readPartitionBoundSpec(), _readPartitionedRelPruneInfo(), _readPartitionPruneInfo(), _readPartitionPruneStepCombine(), _readPartitionPruneStepOp(), _readPartitionRangeDatum(), _readPlanInvalItem(), _readPlannedStmt(), _readPlanRowMark(), _readQuery(), _readRangeTblEntry(), _readRangeTblFunction(), _readRangeTblRef(), _readRangeVar(), _readRecursiveUnion(), _readRelabelType(), _readResult(), _readRowCompareExpr(), _readRowExpr(), _readRowMarkClause(), _readSampleScan(), _readScalarArrayOpExpr(), _readSetOp(), _readSetOperationStmt(), _readSetToDefault(), _readSort(), _readSortGroupClause(), _readSQLValueFunction(), _readSubLink(), _readSubPlan(), _readSubqueryScan(), _readSubscriptingRef(), _readTableFunc(), _readTableFuncScan(), _readTableSampleClause(), _readTargetEntry(), _readTidScan(), _readUnique(), _readValuesScan(), _readVar(), _readWindowAgg(), _readWindowClause(), _readWindowFunc(), _readWithCheckOption(), _readWorkTableScan(), and _readXmlExpr().

◆ READ_LOCALS_NO_FIELDS

#define READ_LOCALS_NO_FIELDS (   nodeTypeName)    nodeTypeName *local_node = makeNode(nodeTypeName)

◆ READ_LOCATION_FIELD

◆ READ_LONG_FIELD

#define READ_LONG_FIELD (   fldname)
Value:
token = pg_strtok(&length); /* skip :fldname */ \
token = pg_strtok(&length); /* get field value */ \
local_node->fldname = atol(token)
const char * pg_strtok(int *length)
Definition: read.c:152

Definition at line 86 of file readfuncs.c.

Referenced by _readAgg(), _readRecursiveUnion(), and _readSetOp().

◆ READ_NODE_FIELD

#define READ_NODE_FIELD (   fldname)
Value:
token = pg_strtok(&length); /* skip :fldname */ \
(void) token; /* in case not used elsewhere */ \
local_node->fldname = nodeRead(NULL, 0)
void * nodeRead(const char *token, int tok_len)
Definition: read.c:316
const char * pg_strtok(int *length)
Definition: read.c:152

Definition at line 143 of file readfuncs.c.

Referenced by _readAgg(), _readAggref(), _readAlias(), _readAlternativeSubPlan(), _readAppend(), _readArrayCoerceExpr(), _readArrayExpr(), _readBitmapAnd(), _readBitmapHeapScan(), _readBitmapIndexScan(), _readBitmapOr(), _readBooleanTest(), _readBoolExpr(), _readCaseExpr(), _readCaseWhen(), _readCoalesceExpr(), _readCoerceToDomain(), _readCoerceViaIO(), _readCollateExpr(), _readCommonTableExpr(), _readConvertRowtypeExpr(), _readCustomScan(), _readDeclareCursorStmt(), _readDefElem(), _readDistinctExpr(), _readFieldSelect(), _readFieldStore(), _readForeignScan(), _readFromExpr(), _readFuncExpr(), _readFunctionScan(), _readGroupingFunc(), _readGroupingSet(), _readHash(), _readHashJoin(), _readIndexOnlyScan(), _readIndexScan(), _readInferenceElem(), _readIntoClause(), _readJoinExpr(), _readLimit(), _readLockRows(), _readMergeAppend(), _readMergeJoin(), _readMinMaxExpr(), _readModifyTable(), _readNamedArgExpr(), _readNestLoop(), _readNestLoopParam(), _readNullIfExpr(), _readNullTest(), _readOnConflictExpr(), _readOpExpr(), _readPartitionBoundSpec(), _readPartitionedRelPruneInfo(), _readPartitionPruneInfo(), _readPartitionPruneStepCombine(), _readPartitionPruneStepOp(), _readPartitionRangeDatum(), _readPlannedStmt(), _readQuery(), _readRangeTblEntry(), _readRangeTblFunction(), _readRangeVar(), _readRelabelType(), _readResult(), _readRowCompareExpr(), _readRowExpr(), _readSampleScan(), _readScalarArrayOpExpr(), _readSetOperationStmt(), _readSubLink(), _readSubPlan(), _readSubqueryScan(), _readSubscriptingRef(), _readTableFunc(), _readTableFuncScan(), _readTableSampleClause(), _readTargetEntry(), _readTidScan(), _readValuesScan(), _readWindowAgg(), _readWindowClause(), _readWindowFunc(), _readWithCheckOption(), _readXmlExpr(), ReadCommonJoin(), and ReadCommonPlan().

◆ READ_OID_ARRAY

#define READ_OID_ARRAY (   fldname,
  len 
)
Value:
token = pg_strtok(&length); /* skip :fldname */ \
local_node->fldname = readOidCols(len);
Oid * readOidCols(int numCols)
Definition: readfuncs.c:2911
const char * pg_strtok(int *length)
Definition: read.c:152

Definition at line 160 of file readfuncs.c.

Referenced by _readAgg(), _readGatherMerge(), _readGroup(), _readMergeAppend(), _readMergeJoin(), _readPartitionedRelPruneInfo(), _readRecursiveUnion(), _readSetOp(), _readSort(), _readUnique(), and _readWindowAgg().

◆ READ_OID_FIELD

◆ READ_STRING_FIELD

#define READ_STRING_FIELD (   fldname)
Value:
token = pg_strtok(&length); /* skip :fldname */ \
token = pg_strtok(&length); /* get field value */ \
local_node->fldname = nullable_string(token, length)
const char * pg_strtok(int *length)
Definition: read.c:152
#define nullable_string(token, length)
Definition: readfuncs.c:189

Definition at line 123 of file readfuncs.c.

Referenced by _readAlias(), _readCommonTableExpr(), _readCurrentOfExpr(), _readDeclareCursorStmt(), _readDefElem(), _readIntoClause(), _readNamedArgExpr(), _readNamedTuplestoreScan(), _readNotifyStmt(), _readRangeTblEntry(), _readRangeVar(), _readSubPlan(), _readTargetEntry(), _readWindowClause(), _readWithCheckOption(), and _readXmlExpr().

◆ READ_TEMP_LOCALS

#define READ_TEMP_LOCALS ( )
Value:
const char *token; \
int length

Definition at line 58 of file readfuncs.c.

Referenced by _readBitmapset(), _readExtensibleNode(), parseNodeString(), ReadCommonJoin(), ReadCommonPlan(), and ReadCommonScan().

◆ READ_UINT64_FIELD

#define READ_UINT64_FIELD (   fldname)
Value:
token = pg_strtok(&length); /* skip :fldname */ \
token = pg_strtok(&length); /* get field value */ \
local_node->fldname = pg_strtouint64(token, NULL, 10)
uint64 pg_strtouint64(const char *str, char **endptr, int base)
Definition: numutils.c:558
const char * pg_strtok(int *length)
Definition: read.c:152

Definition at line 80 of file readfuncs.c.

Referenced by _readPlannedStmt().

◆ READ_UINT_FIELD

#define READ_UINT_FIELD (   fldname)
Value:
token = pg_strtok(&length); /* skip :fldname */ \
token = pg_strtok(&length); /* get field value */ \
local_node->fldname = atoui(token)
#define atoui(x)
Definition: readfuncs.c:185
const char * pg_strtok(int *length)
Definition: read.c:152

Definition at line 74 of file readfuncs.c.

Referenced by _readAggref(), _readCurrentOfExpr(), _readCustomScan(), _readGroupingFunc(), _readModifyTable(), _readPartitionedRelPruneInfo(), _readPlanInvalItem(), _readPlanRowMark(), _readRangeTblEntry(), _readRowMarkClause(), _readSortGroupClause(), _readTargetEntry(), _readVar(), _readWindowAgg(), _readWindowClause(), _readWindowFunc(), and ReadCommonScan().

◆ strtobool

#define strtobool (   x)    ((*(x) == 't') ? true : false)

Definition at line 187 of file readfuncs.c.

Referenced by readBoolCols().

Function Documentation

◆ _readAgg()

static Agg* _readAgg ( void  )
static

Definition at line 2160 of file readfuncs.c.

References READ_ATTRNUMBER_ARRAY, READ_BITMAPSET_FIELD, READ_DONE, READ_ENUM_FIELD, READ_INT_FIELD, READ_LOCALS, READ_LONG_FIELD, READ_NODE_FIELD, READ_OID_ARRAY, and ReadCommonPlan().

Referenced by parseNodeString().

2161 {
2162  READ_LOCALS(Agg);
2163 
2164  ReadCommonPlan(&local_node->plan);
2165 
2166  READ_ENUM_FIELD(aggstrategy, AggStrategy);
2167  READ_ENUM_FIELD(aggsplit, AggSplit);
2168  READ_INT_FIELD(numCols);
2169  READ_ATTRNUMBER_ARRAY(grpColIdx, local_node->numCols);
2170  READ_OID_ARRAY(grpOperators, local_node->numCols);
2171  READ_OID_ARRAY(grpCollations, local_node->numCols);
2172  READ_LONG_FIELD(numGroups);
2173  READ_BITMAPSET_FIELD(aggParams);
2174  READ_NODE_FIELD(groupingSets);
2175  READ_NODE_FIELD(chain);
2176 
2177  READ_DONE();
2178 }
#define READ_LONG_FIELD(fldname)
Definition: readfuncs.c:86
static void ReadCommonPlan(Plan *local_node)
Definition: readfuncs.c:1533
#define READ_OID_ARRAY(fldname, len)
Definition: readfuncs.c:160
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
AggSplit
Definition: nodes.h:776
#define READ_BITMAPSET_FIELD(fldname)
Definition: readfuncs.c:149
AggStrategy
Definition: nodes.h:754
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68
Definition: plannodes.h:802
#define READ_ATTRNUMBER_ARRAY(fldname, len)
Definition: readfuncs.c:155

◆ _readAggref()

static Aggref* _readAggref ( void  )
static

Definition at line 597 of file readfuncs.c.

References generate_unaccent_rules::args, READ_BOOL_FIELD, READ_CHAR_FIELD, READ_DONE, READ_ENUM_FIELD, READ_LOCALS, READ_LOCATION_FIELD, READ_NODE_FIELD, READ_OID_FIELD, and READ_UINT_FIELD.

Referenced by parseNodeString().

598 {
600 
601  READ_OID_FIELD(aggfnoid);
602  READ_OID_FIELD(aggtype);
603  READ_OID_FIELD(aggcollid);
604  READ_OID_FIELD(inputcollid);
605  READ_OID_FIELD(aggtranstype);
606  READ_NODE_FIELD(aggargtypes);
607  READ_NODE_FIELD(aggdirectargs);
609  READ_NODE_FIELD(aggorder);
610  READ_NODE_FIELD(aggdistinct);
611  READ_NODE_FIELD(aggfilter);
612  READ_BOOL_FIELD(aggstar);
613  READ_BOOL_FIELD(aggvariadic);
614  READ_CHAR_FIELD(aggkind);
615  READ_UINT_FIELD(agglevelsup);
616  READ_ENUM_FIELD(aggsplit, AggSplit);
617  READ_LOCATION_FIELD(location);
618 
619  READ_DONE();
620 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
#define READ_CHAR_FIELD(fldname)
Definition: readfuncs.c:98
#define READ_UINT_FIELD(fldname)
Definition: readfuncs.c:74
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
AggSplit
Definition: nodes.h:776
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readAlias()

static Alias* _readAlias ( void  )
static

Definition at line 460 of file readfuncs.c.

References READ_DONE, READ_LOCALS, READ_NODE_FIELD, and READ_STRING_FIELD.

Referenced by parseNodeString().

461 {
463 
464  READ_STRING_FIELD(aliasname);
465  READ_NODE_FIELD(colnames);
466 
467  READ_DONE();
468 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_STRING_FIELD(fldname)
Definition: readfuncs.c:123
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readAlternativeSubPlan()

static AlternativeSubPlan* _readAlternativeSubPlan ( void  )
static

Definition at line 2479 of file readfuncs.c.

References READ_DONE, READ_LOCALS, and READ_NODE_FIELD.

Referenced by parseNodeString().

2480 {
2482 
2483  READ_NODE_FIELD(subplans);
2484 
2485  READ_DONE();
2486 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readAppend()

static Append* _readAppend ( void  )
static

Definition at line 1633 of file readfuncs.c.

References READ_DONE, READ_INT_FIELD, READ_LOCALS, READ_NODE_FIELD, and ReadCommonPlan().

Referenced by parseNodeString().

1634 {
1636 
1637  ReadCommonPlan(&local_node->plan);
1638 
1639  READ_NODE_FIELD(appendplans);
1640  READ_INT_FIELD(first_partial_plan);
1641  READ_NODE_FIELD(part_prune_info);
1642 
1643  READ_DONE();
1644 }
static void ReadCommonPlan(Plan *local_node)
Definition: readfuncs.c:1533
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readArrayCoerceExpr()

static ArrayCoerceExpr* _readArrayCoerceExpr ( void  )
static

Definition at line 916 of file readfuncs.c.

References arg, READ_DONE, READ_ENUM_FIELD, READ_INT_FIELD, READ_LOCALS, READ_LOCATION_FIELD, READ_NODE_FIELD, and READ_OID_FIELD.

Referenced by parseNodeString().

917 {
919 
921  READ_NODE_FIELD(elemexpr);
922  READ_OID_FIELD(resulttype);
923  READ_INT_FIELD(resulttypmod);
924  READ_OID_FIELD(resultcollid);
925  READ_ENUM_FIELD(coerceformat, CoercionForm);
926  READ_LOCATION_FIELD(location);
927 
928  READ_DONE();
929 }
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
void * arg
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68
CoercionForm
Definition: primnodes.h:442

◆ _readArrayExpr()

static ArrayExpr* _readArrayExpr ( void  )
static

Definition at line 1014 of file readfuncs.c.

References READ_BOOL_FIELD, READ_DONE, READ_LOCALS, READ_LOCATION_FIELD, READ_NODE_FIELD, and READ_OID_FIELD.

Referenced by parseNodeString().

1015 {
1017 
1018  READ_OID_FIELD(array_typeid);
1019  READ_OID_FIELD(array_collid);
1020  READ_OID_FIELD(element_typeid);
1021  READ_NODE_FIELD(elements);
1022  READ_BOOL_FIELD(multidims);
1023  READ_LOCATION_FIELD(location);
1024 
1025  READ_DONE();
1026 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readBitmapAnd()

static BitmapAnd* _readBitmapAnd ( void  )
static

Definition at line 1691 of file readfuncs.c.

References READ_DONE, READ_LOCALS, READ_NODE_FIELD, and ReadCommonPlan().

Referenced by parseNodeString().

1692 {
1694 
1695  ReadCommonPlan(&local_node->plan);
1696 
1697  READ_NODE_FIELD(bitmapplans);
1698 
1699  READ_DONE();
1700 }
static void ReadCommonPlan(Plan *local_node)
Definition: readfuncs.c:1533
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readBitmapHeapScan()

static BitmapHeapScan* _readBitmapHeapScan ( void  )
static

Definition at line 1835 of file readfuncs.c.

References READ_DONE, READ_LOCALS, READ_NODE_FIELD, and ReadCommonScan().

Referenced by parseNodeString().

1836 {
1838 
1839  ReadCommonScan(&local_node->scan);
1840 
1841  READ_NODE_FIELD(bitmapqualorig);
1842 
1843  READ_DONE();
1844 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
static void ReadCommonScan(Scan *local_node)
Definition: readfuncs.c:1723
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readBitmapIndexScan()

static BitmapIndexScan* _readBitmapIndexScan ( void  )
static

Definition at line 1817 of file readfuncs.c.

References READ_BOOL_FIELD, READ_DONE, READ_LOCALS, READ_NODE_FIELD, READ_OID_FIELD, and ReadCommonScan().

Referenced by parseNodeString().

1818 {
1820 
1821  ReadCommonScan(&local_node->scan);
1822 
1823  READ_OID_FIELD(indexid);
1824  READ_BOOL_FIELD(isshared);
1825  READ_NODE_FIELD(indexqual);
1826  READ_NODE_FIELD(indexqualorig);
1827 
1828  READ_DONE();
1829 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
static void ReadCommonScan(Scan *local_node)
Definition: readfuncs.c:1723
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readBitmapOr()

static BitmapOr* _readBitmapOr ( void  )
static

Definition at line 1706 of file readfuncs.c.

References READ_BOOL_FIELD, READ_DONE, READ_LOCALS, READ_NODE_FIELD, and ReadCommonPlan().

Referenced by parseNodeString().

1707 {
1709 
1710  ReadCommonPlan(&local_node->plan);
1711 
1712  READ_BOOL_FIELD(isshared);
1713  READ_NODE_FIELD(bitmapplans);
1714 
1715  READ_DONE();
1716 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
static void ReadCommonPlan(Plan *local_node)
Definition: readfuncs.c:1533
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readBitmapset()

static Bitmapset* _readBitmapset ( void  )
static

Definition at line 197 of file readfuncs.c.

References bms_add_member(), elog, ERROR, pg_strtok(), READ_TEMP_LOCALS, and val.

Referenced by readBitmapset().

198 {
199  Bitmapset *result = NULL;
200 
202 
203  token = pg_strtok(&length);
204  if (token == NULL)
205  elog(ERROR, "incomplete Bitmapset structure");
206  if (length != 1 || token[0] != '(')
207  elog(ERROR, "unrecognized token: \"%.*s\"", length, token);
208 
209  token = pg_strtok(&length);
210  if (token == NULL)
211  elog(ERROR, "incomplete Bitmapset structure");
212  if (length != 1 || token[0] != 'b')
213  elog(ERROR, "unrecognized token: \"%.*s\"", length, token);
214 
215  for (;;)
216  {
217  int val;
218  char *endptr;
219 
220  token = pg_strtok(&length);
221  if (token == NULL)
222  elog(ERROR, "unterminated Bitmapset structure");
223  if (length == 1 && token[0] == ')')
224  break;
225  val = (int) strtol(token, &endptr, 10);
226  if (endptr != token + length)
227  elog(ERROR, "unrecognized integer: \"%.*s\"", length, token);
228  result = bms_add_member(result, val);
229  }
230 
231  return result;
232 }
#define ERROR
Definition: elog.h:43
#define READ_TEMP_LOCALS()
Definition: readfuncs.c:58
Bitmapset * bms_add_member(Bitmapset *a, int x)
Definition: bitmapset.c:736
#define elog(elevel,...)
Definition: elog.h:226
const char * pg_strtok(int *length)
Definition: read.c:152
long val
Definition: informix.c:684

◆ _readBooleanTest()

static BooleanTest* _readBooleanTest ( void  )
static

Definition at line 1154 of file readfuncs.c.

References arg, READ_DONE, READ_ENUM_FIELD, READ_LOCALS, READ_LOCATION_FIELD, and READ_NODE_FIELD.

Referenced by parseNodeString().

1155 {
1157 
1159  READ_ENUM_FIELD(booltesttype, BoolTestType);
1160  READ_LOCATION_FIELD(location);
1161 
1162  READ_DONE();
1163 }
BoolTestType
Definition: primnodes.h:1220
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
void * arg
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readBoolExpr()

static BoolExpr* _readBoolExpr ( void  )
static

Definition at line 800 of file readfuncs.c.

References AND_EXPR, generate_unaccent_rules::args, elog, ERROR, NOT_EXPR, OR_EXPR, pg_strtok(), READ_DONE, READ_LOCALS, READ_LOCATION_FIELD, and READ_NODE_FIELD.

Referenced by parseNodeString().

801 {
803 
804  /* do-it-yourself enum representation */
805  token = pg_strtok(&length); /* skip :boolop */
806  token = pg_strtok(&length); /* get field value */
807  if (strncmp(token, "and", 3) == 0)
808  local_node->boolop = AND_EXPR;
809  else if (strncmp(token, "or", 2) == 0)
810  local_node->boolop = OR_EXPR;
811  else if (strncmp(token, "not", 3) == 0)
812  local_node->boolop = NOT_EXPR;
813  else
814  elog(ERROR, "unrecognized boolop \"%.*s\"", length, token);
815 
817  READ_LOCATION_FIELD(location);
818 
819  READ_DONE();
820 }
#define ERROR
Definition: elog.h:43
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define elog(elevel,...)
Definition: elog.h:226
const char * pg_strtok(int *length)
Definition: read.c:152
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readCaseExpr()

static CaseExpr* _readCaseExpr ( void  )
static

Definition at line 966 of file readfuncs.c.

References arg, generate_unaccent_rules::args, READ_DONE, READ_LOCALS, READ_LOCATION_FIELD, READ_NODE_FIELD, and READ_OID_FIELD.

Referenced by parseNodeString().

967 {
969 
970  READ_OID_FIELD(casetype);
971  READ_OID_FIELD(casecollid);
974  READ_NODE_FIELD(defresult);
975  READ_LOCATION_FIELD(location);
976 
977  READ_DONE();
978 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
void * arg
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readCaseTestExpr()

static CaseTestExpr* _readCaseTestExpr ( void  )
static

Definition at line 999 of file readfuncs.c.

References READ_DONE, READ_INT_FIELD, READ_LOCALS, and READ_OID_FIELD.

Referenced by parseNodeString().

1000 {
1002 
1003  READ_OID_FIELD(typeId);
1004  READ_INT_FIELD(typeMod);
1005  READ_OID_FIELD(collation);
1006 
1007  READ_DONE();
1008 }
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readCaseWhen()

static CaseWhen* _readCaseWhen ( void  )
static

Definition at line 984 of file readfuncs.c.

References READ_DONE, READ_LOCALS, READ_LOCATION_FIELD, and READ_NODE_FIELD.

Referenced by parseNodeString().

985 {
987 
988  READ_NODE_FIELD(expr);
989  READ_NODE_FIELD(result);
990  READ_LOCATION_FIELD(location);
991 
992  READ_DONE();
993 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readCoalesceExpr()

static CoalesceExpr* _readCoalesceExpr ( void  )
static

Definition at line 1067 of file readfuncs.c.

References generate_unaccent_rules::args, READ_DONE, READ_LOCALS, READ_LOCATION_FIELD, READ_NODE_FIELD, and READ_OID_FIELD.

Referenced by parseNodeString().

1068 {
1070 
1071  READ_OID_FIELD(coalescetype);
1072  READ_OID_FIELD(coalescecollid);
1074  READ_LOCATION_FIELD(location);
1075 
1076  READ_DONE();
1077 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readCoerceToDomain()

static CoerceToDomain* _readCoerceToDomain ( void  )
static

Definition at line 1169 of file readfuncs.c.

References arg, READ_DONE, READ_ENUM_FIELD, READ_INT_FIELD, READ_LOCALS, READ_LOCATION_FIELD, READ_NODE_FIELD, and READ_OID_FIELD.

Referenced by parseNodeString().

1170 {
1172 
1174  READ_OID_FIELD(resulttype);
1175  READ_INT_FIELD(resulttypmod);
1176  READ_OID_FIELD(resultcollid);
1177  READ_ENUM_FIELD(coercionformat, CoercionForm);
1178  READ_LOCATION_FIELD(location);
1179 
1180  READ_DONE();
1181 }
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
void * arg
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68
CoercionForm
Definition: primnodes.h:442

◆ _readCoerceToDomainValue()

static CoerceToDomainValue* _readCoerceToDomainValue ( void  )
static

Definition at line 1187 of file readfuncs.c.

References READ_DONE, READ_INT_FIELD, READ_LOCALS, READ_LOCATION_FIELD, and READ_OID_FIELD.

Referenced by parseNodeString().

1188 {
1190 
1191  READ_OID_FIELD(typeId);
1192  READ_INT_FIELD(typeMod);
1193  READ_OID_FIELD(collation);
1194  READ_LOCATION_FIELD(location);
1195 
1196  READ_DONE();
1197 }
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readCoerceViaIO()

static CoerceViaIO* _readCoerceViaIO ( void  )
static

Definition at line 899 of file readfuncs.c.

References arg, READ_DONE, READ_ENUM_FIELD, READ_LOCALS, READ_LOCATION_FIELD, READ_NODE_FIELD, and READ_OID_FIELD.

Referenced by parseNodeString().

900 {
902 
904  READ_OID_FIELD(resulttype);
905  READ_OID_FIELD(resultcollid);
906  READ_ENUM_FIELD(coerceformat, CoercionForm);
907  READ_LOCATION_FIELD(location);
908 
909  READ_DONE();
910 }
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
void * arg
#define READ_DONE()
Definition: readfuncs.c:175
CoercionForm
Definition: primnodes.h:442

◆ _readCollateExpr()

static CollateExpr* _readCollateExpr ( void  )
static

Definition at line 951 of file readfuncs.c.

References arg, READ_DONE, READ_LOCALS, READ_LOCATION_FIELD, READ_NODE_FIELD, and READ_OID_FIELD.

Referenced by parseNodeString().

952 {
954 
956  READ_OID_FIELD(collOid);
957  READ_LOCATION_FIELD(location);
958 
959  READ_DONE();
960 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
void * arg
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readCommonTableExpr()

static CommonTableExpr* _readCommonTableExpr ( void  )
static

Definition at line 415 of file readfuncs.c.

References READ_BOOL_FIELD, READ_DONE, READ_ENUM_FIELD, READ_INT_FIELD, READ_LOCALS, READ_LOCATION_FIELD, READ_NODE_FIELD, and READ_STRING_FIELD.

Referenced by parseNodeString().

416 {
418 
419  READ_STRING_FIELD(ctename);
420  READ_NODE_FIELD(aliascolnames);
421  READ_ENUM_FIELD(ctematerialized, CTEMaterialize);
422  READ_NODE_FIELD(ctequery);
423  READ_LOCATION_FIELD(location);
424  READ_BOOL_FIELD(cterecursive);
425  READ_INT_FIELD(cterefcount);
426  READ_NODE_FIELD(ctecolnames);
427  READ_NODE_FIELD(ctecoltypes);
428  READ_NODE_FIELD(ctecoltypmods);
429  READ_NODE_FIELD(ctecolcollations);
430 
431  READ_DONE();
432 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
CTEMaterialize
Definition: parsenodes.h:1417
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_STRING_FIELD(fldname)
Definition: readfuncs.c:123
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readConst()

static Const* _readConst ( void  )
static

Definition at line 554 of file readfuncs.c.

References pg_strtok(), READ_BOOL_FIELD, READ_DONE, READ_INT_FIELD, READ_LOCALS, READ_LOCATION_FIELD, READ_OID_FIELD, and readDatum().

Referenced by parseNodeString().

555 {
557 
558  READ_OID_FIELD(consttype);
559  READ_INT_FIELD(consttypmod);
560  READ_OID_FIELD(constcollid);
561  READ_INT_FIELD(constlen);
562  READ_BOOL_FIELD(constbyval);
563  READ_BOOL_FIELD(constisnull);
564  READ_LOCATION_FIELD(location);
565 
566  token = pg_strtok(&length); /* skip :constvalue */
567  if (local_node->constisnull)
568  token = pg_strtok(&length); /* skip "<>" */
569  else
570  local_node->constvalue = readDatum(local_node->constbyval);
571 
572  READ_DONE();
573 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
Datum readDatum(bool typbyval)
Definition: readfuncs.c:2830
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
const char * pg_strtok(int *length)
Definition: read.c:152
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readConvertRowtypeExpr()

static ConvertRowtypeExpr* _readConvertRowtypeExpr ( void  )
static

Definition at line 935 of file readfuncs.c.

References arg, READ_DONE, READ_ENUM_FIELD, READ_LOCALS, READ_LOCATION_FIELD, READ_NODE_FIELD, and READ_OID_FIELD.

Referenced by parseNodeString().

936 {
938 
940  READ_OID_FIELD(resulttype);
941  READ_ENUM_FIELD(convertformat, CoercionForm);
942  READ_LOCATION_FIELD(location);
943 
944  READ_DONE();
945 }
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
void * arg
#define READ_DONE()
Definition: readfuncs.c:175
CoercionForm
Definition: primnodes.h:442

◆ _readCteScan()

static CteScan* _readCteScan ( void  )
static

Definition at line 1926 of file readfuncs.c.

References READ_DONE, READ_INT_FIELD, READ_LOCALS, and ReadCommonScan().

Referenced by parseNodeString().

1927 {
1929 
1930  ReadCommonScan(&local_node->scan);
1931 
1932  READ_INT_FIELD(ctePlanId);
1933  READ_INT_FIELD(cteParam);
1934 
1935  READ_DONE();
1936 }
static void ReadCommonScan(Scan *local_node)
Definition: readfuncs.c:1723
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readCurrentOfExpr()

static CurrentOfExpr* _readCurrentOfExpr ( void  )
static

Definition at line 1219 of file readfuncs.c.

References READ_DONE, READ_INT_FIELD, READ_LOCALS, READ_STRING_FIELD, and READ_UINT_FIELD.

Referenced by parseNodeString().

1220 {
1222 
1223  READ_UINT_FIELD(cvarno);
1224  READ_STRING_FIELD(cursor_name);
1225  READ_INT_FIELD(cursor_param);
1226 
1227  READ_DONE();
1228 }
#define READ_UINT_FIELD(fldname)
Definition: readfuncs.c:74
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_STRING_FIELD(fldname)
Definition: readfuncs.c:123
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readCustomScan()

static CustomScan* _readCustomScan ( void  )
static

Definition at line 1994 of file readfuncs.c.

References GetCustomScanMethods(), nullable_string, pg_strtok(), READ_BITMAPSET_FIELD, READ_DONE, READ_LOCALS, READ_NODE_FIELD, READ_UINT_FIELD, and ReadCommonScan().

Referenced by parseNodeString().

1995 {
1997  char *custom_name;
1998  const CustomScanMethods *methods;
1999 
2000  ReadCommonScan(&local_node->scan);
2001 
2002  READ_UINT_FIELD(flags);
2003  READ_NODE_FIELD(custom_plans);
2004  READ_NODE_FIELD(custom_exprs);
2005  READ_NODE_FIELD(custom_private);
2006  READ_NODE_FIELD(custom_scan_tlist);
2007  READ_BITMAPSET_FIELD(custom_relids);
2008 
2009  /* Lookup CustomScanMethods by CustomName */
2010  token = pg_strtok(&length); /* skip methods: */
2011  token = pg_strtok(&length); /* CustomName */
2012  custom_name = nullable_string(token, length);
2013  methods = GetCustomScanMethods(custom_name, false);
2014  local_node->methods = methods;
2015 
2016  READ_DONE();
2017 }
#define READ_UINT_FIELD(fldname)
Definition: readfuncs.c:74
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
static void ReadCommonScan(Scan *local_node)
Definition: readfuncs.c:1723
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_BITMAPSET_FIELD(fldname)
Definition: readfuncs.c:149
const char * pg_strtok(int *length)
Definition: read.c:152
#define READ_DONE()
Definition: readfuncs.c:175
const CustomScanMethods * GetCustomScanMethods(const char *CustomName, bool missing_ok)
Definition: extensible.c:137
#define nullable_string(token, length)
Definition: readfuncs.c:189

◆ _readDeclareCursorStmt()

static DeclareCursorStmt* _readDeclareCursorStmt ( void  )
static

Definition at line 309 of file readfuncs.c.

References READ_DONE, READ_INT_FIELD, READ_LOCALS, READ_NODE_FIELD, and READ_STRING_FIELD.

Referenced by parseNodeString().

310 {
312 
313  READ_STRING_FIELD(portalname);
315  READ_NODE_FIELD(query);
316 
317  READ_DONE();
318 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_STRING_FIELD(fldname)
Definition: readfuncs.c:123
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readDefElem()

static DefElem* _readDefElem ( void  )
static

Definition at line 1477 of file readfuncs.c.

References arg, READ_DONE, READ_ENUM_FIELD, READ_LOCALS, READ_LOCATION_FIELD, READ_NODE_FIELD, and READ_STRING_FIELD.

Referenced by parseNodeString().

1478 {
1480 
1481  READ_STRING_FIELD(defnamespace);
1482  READ_STRING_FIELD(defname);
1484  READ_ENUM_FIELD(defaction, DefElemAction);
1485  READ_LOCATION_FIELD(location);
1486 
1487  READ_DONE();
1488 }
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
DefElemAction
Definition: parsenodes.h:718
void * arg
#define READ_STRING_FIELD(fldname)
Definition: readfuncs.c:123
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readDistinctExpr()

static DistinctExpr* _readDistinctExpr ( void  )
static

Definition at line 742 of file readfuncs.c.

References generate_unaccent_rules::args, READ_BOOL_FIELD, READ_DONE, READ_LOCALS, READ_LOCATION_FIELD, READ_NODE_FIELD, and READ_OID_FIELD.

Referenced by parseNodeString().

743 {
745 
746  READ_OID_FIELD(opno);
747  READ_OID_FIELD(opfuncid);
748  READ_OID_FIELD(opresulttype);
749  READ_BOOL_FIELD(opretset);
750  READ_OID_FIELD(opcollid);
751  READ_OID_FIELD(inputcollid);
753  READ_LOCATION_FIELD(location);
754 
755  READ_DONE();
756 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readExtensibleNode()

static ExtensibleNode* _readExtensibleNode ( void  )
static

Definition at line 2492 of file readfuncs.c.

References elog, ERROR, ExtensibleNode::extnodename, GetExtensibleNodeMethods(), newNode, ExtensibleNodeMethods::node_size, ExtensibleNodeMethods::nodeRead, nullable_string, pg_strtok(), READ_DONE, READ_TEMP_LOCALS, and T_ExtensibleNode.

Referenced by parseNodeString().

2493 {
2494  const ExtensibleNodeMethods *methods;
2495  ExtensibleNode *local_node;
2496  const char *extnodename;
2497 
2498  READ_TEMP_LOCALS();
2499 
2500  token = pg_strtok(&length); /* skip :extnodename */
2501  token = pg_strtok(&length); /* get extnodename */
2502 
2503  extnodename = nullable_string(token, length);
2504  if (!extnodename)
2505  elog(ERROR, "extnodename has to be supplied");
2506  methods = GetExtensibleNodeMethods(extnodename, false);
2507 
2508  local_node = (ExtensibleNode *) newNode(methods->node_size,
2510  local_node->extnodename = extnodename;
2511 
2512  /* deserialize the private fields */
2513  methods->nodeRead(local_node);
2514 
2515  READ_DONE();
2516 }
#define newNode(size, tag)
Definition: nodes.h:563
#define ERROR
Definition: elog.h:43
#define READ_TEMP_LOCALS()
Definition: readfuncs.c:58
const char * extnodename
Definition: extensible.h:35
void(* nodeRead)(struct ExtensibleNode *node)
Definition: extensible.h:70
#define elog(elevel,...)
Definition: elog.h:226
const char * pg_strtok(int *length)
Definition: read.c:152
#define READ_DONE()
Definition: readfuncs.c:175
const ExtensibleNodeMethods * GetExtensibleNodeMethods(const char *extnodename, bool missing_ok)
Definition: extensible.c:125
#define nullable_string(token, length)
Definition: readfuncs.c:189

◆ _readFieldSelect()

static FieldSelect* _readFieldSelect ( void  )
static

Definition at line 848 of file readfuncs.c.

References arg, READ_DONE, READ_INT_FIELD, READ_LOCALS, READ_NODE_FIELD, and READ_OID_FIELD.

Referenced by parseNodeString().

849 {
851 
853  READ_INT_FIELD(fieldnum);
854  READ_OID_FIELD(resulttype);
855  READ_INT_FIELD(resulttypmod);
856  READ_OID_FIELD(resultcollid);
857 
858  READ_DONE();
859 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
void * arg
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readFieldStore()

static FieldStore* _readFieldStore ( void  )
static

Definition at line 865 of file readfuncs.c.

References arg, READ_DONE, READ_LOCALS, READ_NODE_FIELD, and READ_OID_FIELD.

Referenced by parseNodeString().

866 {
868 
870  READ_NODE_FIELD(newvals);
871  READ_NODE_FIELD(fieldnums);
872  READ_OID_FIELD(resulttype);
873 
874  READ_DONE();
875 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
void * arg
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readForeignScan()

static ForeignScan* _readForeignScan ( void  )
static

Definition at line 1972 of file readfuncs.c.

References READ_BITMAPSET_FIELD, READ_BOOL_FIELD, READ_DONE, READ_ENUM_FIELD, READ_LOCALS, READ_NODE_FIELD, READ_OID_FIELD, and ReadCommonScan().

Referenced by parseNodeString().

1973 {
1975 
1976  ReadCommonScan(&local_node->scan);
1977 
1978  READ_ENUM_FIELD(operation, CmdType);
1979  READ_OID_FIELD(fs_server);
1980  READ_NODE_FIELD(fdw_exprs);
1981  READ_NODE_FIELD(fdw_private);
1982  READ_NODE_FIELD(fdw_scan_tlist);
1983  READ_NODE_FIELD(fdw_recheck_quals);
1984  READ_BITMAPSET_FIELD(fs_relids);
1985  READ_BOOL_FIELD(fsSystemCol);
1986 
1987  READ_DONE();
1988 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
static void ReadCommonScan(Scan *local_node)
Definition: readfuncs.c:1723
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_BITMAPSET_FIELD(fldname)
Definition: readfuncs.c:149
#define READ_DONE()
Definition: readfuncs.c:175
CmdType
Definition: nodes.h:668

◆ _readFromExpr()

static FromExpr* _readFromExpr ( void  )
static

Definition at line 1315 of file readfuncs.c.

References READ_DONE, READ_LOCALS, and READ_NODE_FIELD.

Referenced by parseNodeString().

1316 {
1318 
1319  READ_NODE_FIELD(fromlist);
1320  READ_NODE_FIELD(quals);
1321 
1322  READ_DONE();
1323 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readFuncExpr()

static FuncExpr* _readFuncExpr ( void  )
static

Definition at line 685 of file readfuncs.c.

References generate_unaccent_rules::args, READ_BOOL_FIELD, READ_DONE, READ_ENUM_FIELD, READ_LOCALS, READ_LOCATION_FIELD, READ_NODE_FIELD, and READ_OID_FIELD.

Referenced by parseNodeString().

686 {
688 
689  READ_OID_FIELD(funcid);
690  READ_OID_FIELD(funcresulttype);
691  READ_BOOL_FIELD(funcretset);
692  READ_BOOL_FIELD(funcvariadic);
693  READ_ENUM_FIELD(funcformat, CoercionForm);
694  READ_OID_FIELD(funccollid);
695  READ_OID_FIELD(inputcollid);
697  READ_LOCATION_FIELD(location);
698 
699  READ_DONE();
700 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175
CoercionForm
Definition: primnodes.h:442

◆ _readFunctionScan()

static FunctionScan* _readFunctionScan ( void  )
static

Definition at line 1880 of file readfuncs.c.

References functions, READ_BOOL_FIELD, READ_DONE, READ_LOCALS, READ_NODE_FIELD, and ReadCommonScan().

Referenced by parseNodeString().

1881 {
1883 
1884  ReadCommonScan(&local_node->scan);
1885 
1887  READ_BOOL_FIELD(funcordinality);
1888 
1889  READ_DONE();
1890 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
static void ReadCommonScan(Scan *local_node)
Definition: readfuncs.c:1723
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
static const struct fns functions
Definition: regcomp.c:298
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readGather()

static Gather* _readGather ( void  )
static

Definition at line 2233 of file readfuncs.c.

References READ_BITMAPSET_FIELD, READ_BOOL_FIELD, READ_DONE, READ_INT_FIELD, READ_LOCALS, and ReadCommonPlan().

Referenced by parseNodeString().

2234 {
2236 
2237  ReadCommonPlan(&local_node->plan);
2238 
2239  READ_INT_FIELD(num_workers);
2240  READ_INT_FIELD(rescan_param);
2241  READ_BOOL_FIELD(single_copy);
2242  READ_BOOL_FIELD(invisible);
2243  READ_BITMAPSET_FIELD(initParam);
2244 
2245  READ_DONE();
2246 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
static void ReadCommonPlan(Plan *local_node)
Definition: readfuncs.c:1533
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_BITMAPSET_FIELD(fldname)
Definition: readfuncs.c:149
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readGatherMerge()

static GatherMerge* _readGatherMerge ( void  )
static

Definition at line 2252 of file readfuncs.c.

References READ_ATTRNUMBER_ARRAY, READ_BITMAPSET_FIELD, READ_BOOL_ARRAY, READ_DONE, READ_INT_FIELD, READ_LOCALS, READ_OID_ARRAY, and ReadCommonPlan().

Referenced by parseNodeString().

2253 {
2255 
2256  ReadCommonPlan(&local_node->plan);
2257 
2258  READ_INT_FIELD(num_workers);
2259  READ_INT_FIELD(rescan_param);
2260  READ_INT_FIELD(numCols);
2261  READ_ATTRNUMBER_ARRAY(sortColIdx, local_node->numCols);
2262  READ_OID_ARRAY(sortOperators, local_node->numCols);
2263  READ_OID_ARRAY(collations, local_node->numCols);
2264  READ_BOOL_ARRAY(nullsFirst, local_node->numCols);
2265  READ_BITMAPSET_FIELD(initParam);
2266 
2267  READ_DONE();
2268 }
#define READ_BOOL_ARRAY(fldname, len)
Definition: readfuncs.c:170
static void ReadCommonPlan(Plan *local_node)
Definition: readfuncs.c:1533
#define READ_OID_ARRAY(fldname, len)
Definition: readfuncs.c:160
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_BITMAPSET_FIELD(fldname)
Definition: readfuncs.c:149
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68
#define READ_ATTRNUMBER_ARRAY(fldname, len)
Definition: readfuncs.c:155

◆ _readGroup()

static Group* _readGroup ( void  )
static

Definition at line 2142 of file readfuncs.c.

References READ_ATTRNUMBER_ARRAY, READ_DONE, READ_INT_FIELD, READ_LOCALS, READ_OID_ARRAY, and ReadCommonPlan().

Referenced by parseNodeString().

2143 {
2144  READ_LOCALS(Group);
2145 
2146  ReadCommonPlan(&local_node->plan);
2147 
2148  READ_INT_FIELD(numCols);
2149  READ_ATTRNUMBER_ARRAY(grpColIdx, local_node->numCols);
2150  READ_OID_ARRAY(grpOperators, local_node->numCols);
2151  READ_OID_ARRAY(grpCollations, local_node->numCols);
2152 
2153  READ_DONE();
2154 }
static void ReadCommonPlan(Plan *local_node)
Definition: readfuncs.c:1533
#define READ_OID_ARRAY(fldname, len)
Definition: readfuncs.c:160
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68
#define READ_ATTRNUMBER_ARRAY(fldname, len)
Definition: readfuncs.c:155

◆ _readGroupingFunc()

static GroupingFunc* _readGroupingFunc ( void  )
static

Definition at line 626 of file readfuncs.c.

References generate_unaccent_rules::args, READ_DONE, READ_LOCALS, READ_LOCATION_FIELD, READ_NODE_FIELD, and READ_UINT_FIELD.

Referenced by parseNodeString().

627 {
629 
631  READ_NODE_FIELD(refs);
632  READ_NODE_FIELD(cols);
633  READ_UINT_FIELD(agglevelsup);
634  READ_LOCATION_FIELD(location);
635 
636  READ_DONE();
637 }
#define READ_UINT_FIELD(fldname)
Definition: readfuncs.c:74
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readGroupingSet()

static GroupingSet* _readGroupingSet ( void  )
static

Definition at line 358 of file readfuncs.c.

References READ_DONE, READ_ENUM_FIELD, READ_LOCALS, READ_LOCATION_FIELD, and READ_NODE_FIELD.

Referenced by parseNodeString().

359 {
361 
363  READ_NODE_FIELD(content);
364  READ_LOCATION_FIELD(location);
365 
366  READ_DONE();
367 }
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
GroupingSetKind
Definition: parsenodes.h:1291
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readHash()

static Hash* _readHash ( void  )
static

Definition at line 2274 of file readfuncs.c.

References READ_BOOL_FIELD, READ_DONE, READ_FLOAT_FIELD, READ_INT_FIELD, READ_LOCALS, READ_NODE_FIELD, READ_OID_FIELD, and ReadCommonPlan().

Referenced by parseNodeString().

2275 {
2276  READ_LOCALS(Hash);
2277 
2278  ReadCommonPlan(&local_node->plan);
2279 
2280  READ_NODE_FIELD(hashkeys);
2281  READ_OID_FIELD(skewTable);
2282  READ_INT_FIELD(skewColumn);
2283  READ_BOOL_FIELD(skewInherit);
2284  READ_FLOAT_FIELD(rows_total);
2285 
2286  READ_DONE();
2287 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
static void ReadCommonPlan(Plan *local_node)
Definition: readfuncs.c:1533
#define READ_FLOAT_FIELD(fldname)
Definition: readfuncs.c:111
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readHashJoin()

static HashJoin* _readHashJoin ( void  )
static

Definition at line 2092 of file readfuncs.c.

References READ_DONE, READ_LOCALS, READ_NODE_FIELD, and ReadCommonJoin().

Referenced by parseNodeString().

2093 {
2095 
2096  ReadCommonJoin(&local_node->join);
2097 
2098  READ_NODE_FIELD(hashclauses);
2099  READ_NODE_FIELD(hashoperators);
2100  READ_NODE_FIELD(hashcollations);
2101  READ_NODE_FIELD(hashkeys);
2102 
2103  READ_DONE();
2104 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
static void ReadCommonJoin(Join *local_node)
Definition: readfuncs.c:2024
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readIndexOnlyScan()

static IndexOnlyScan* _readIndexOnlyScan ( void  )
static

Definition at line 1798 of file readfuncs.c.

References READ_DONE, READ_ENUM_FIELD, READ_LOCALS, READ_NODE_FIELD, READ_OID_FIELD, and ReadCommonScan().

Referenced by parseNodeString().

1799 {
1801 
1802  ReadCommonScan(&local_node->scan);
1803 
1804  READ_OID_FIELD(indexid);
1805  READ_NODE_FIELD(indexqual);
1806  READ_NODE_FIELD(indexorderby);
1807  READ_NODE_FIELD(indextlist);
1808  READ_ENUM_FIELD(indexorderdir, ScanDirection);
1809 
1810  READ_DONE();
1811 }
ScanDirection
Definition: sdir.h:22
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
static void ReadCommonScan(Scan *local_node)
Definition: readfuncs.c:1723
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readIndexScan()

static IndexScan* _readIndexScan ( void  )
static

Definition at line 1777 of file readfuncs.c.

References READ_DONE, READ_ENUM_FIELD, READ_LOCALS, READ_NODE_FIELD, READ_OID_FIELD, and ReadCommonScan().

Referenced by parseNodeString().

1778 {
1780 
1781  ReadCommonScan(&local_node->scan);
1782 
1783  READ_OID_FIELD(indexid);
1784  READ_NODE_FIELD(indexqual);
1785  READ_NODE_FIELD(indexqualorig);
1786  READ_NODE_FIELD(indexorderby);
1787  READ_NODE_FIELD(indexorderbyorig);
1788  READ_NODE_FIELD(indexorderbyops);
1789  READ_ENUM_FIELD(indexorderdir, ScanDirection);
1790 
1791  READ_DONE();
1792 }
ScanDirection
Definition: sdir.h:22
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
static void ReadCommonScan(Scan *local_node)
Definition: readfuncs.c:1723
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readInferenceElem()

static InferenceElem* _readInferenceElem ( void  )
static

Definition at line 1248 of file readfuncs.c.

References READ_DONE, READ_LOCALS, READ_NODE_FIELD, and READ_OID_FIELD.

Referenced by parseNodeString().

1249 {
1251 
1252  READ_NODE_FIELD(expr);
1253  READ_OID_FIELD(infercollid);
1254  READ_OID_FIELD(inferopclass);
1255 
1256  READ_DONE();
1257 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readIntoClause()

static IntoClause* _readIntoClause ( void  )
static

Definition at line 513 of file readfuncs.c.

References READ_BOOL_FIELD, READ_DONE, READ_ENUM_FIELD, READ_LOCALS, READ_NODE_FIELD, and READ_STRING_FIELD.

Referenced by parseNodeString().

514 {
516 
517  READ_NODE_FIELD(rel);
518  READ_NODE_FIELD(colNames);
519  READ_STRING_FIELD(accessMethod);
521  READ_ENUM_FIELD(onCommit, OnCommitAction);
522  READ_STRING_FIELD(tableSpaceName);
523  READ_NODE_FIELD(viewQuery);
524  READ_BOOL_FIELD(skipData);
525 
526  READ_DONE();
527 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
OnCommitAction
Definition: primnodes.h:47
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_STRING_FIELD(fldname)
Definition: readfuncs.c:123
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readJoin()

static Join* _readJoin ( void  )
static

Definition at line 2039 of file readfuncs.c.

References READ_DONE, READ_LOCALS_NO_FIELDS, and ReadCommonJoin().

Referenced by parseNodeString().

2040 {
2042 
2043  ReadCommonJoin(local_node);
2044 
2045  READ_DONE();
2046 }
#define READ_LOCALS_NO_FIELDS(nodeTypeName)
Definition: readfuncs.c:54
static void ReadCommonJoin(Join *local_node)
Definition: readfuncs.c:2024
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readJoinExpr()

static JoinExpr* _readJoinExpr ( void  )
static

Definition at line 1295 of file readfuncs.c.

References READ_BOOL_FIELD, READ_DONE, READ_ENUM_FIELD, READ_INT_FIELD, READ_LOCALS, and READ_NODE_FIELD.

Referenced by parseNodeString().

1296 {
1298 
1299  READ_ENUM_FIELD(jointype, JoinType);
1300  READ_BOOL_FIELD(isNatural);
1301  READ_NODE_FIELD(larg);
1302  READ_NODE_FIELD(rarg);
1303  READ_NODE_FIELD(usingClause);
1304  READ_NODE_FIELD(quals);
1305  READ_NODE_FIELD(alias);
1306  READ_INT_FIELD(rtindex);
1307 
1308  READ_DONE();
1309 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
JoinType
Definition: nodes.h:692
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readLimit()

static Limit* _readLimit ( void  )
static

Definition at line 2332 of file readfuncs.c.

References READ_DONE, READ_LOCALS, READ_NODE_FIELD, and ReadCommonPlan().

Referenced by parseNodeString().

2333 {
2334  READ_LOCALS(Limit);
2335 
2336  ReadCommonPlan(&local_node->plan);
2337 
2338  READ_NODE_FIELD(limitOffset);
2339  READ_NODE_FIELD(limitCount);
2340 
2341  READ_DONE();
2342 }
static void ReadCommonPlan(Plan *local_node)
Definition: readfuncs.c:1533
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readLockRows()

static LockRows* _readLockRows ( void  )
static

Definition at line 2316 of file readfuncs.c.

References READ_DONE, READ_INT_FIELD, READ_LOCALS, READ_NODE_FIELD, and ReadCommonPlan().

Referenced by parseNodeString().

2317 {
2319 
2320  ReadCommonPlan(&local_node->plan);
2321 
2322  READ_NODE_FIELD(rowMarks);
2323  READ_INT_FIELD(epqParam);
2324 
2325  READ_DONE();
2326 }
static void ReadCommonPlan(Plan *local_node)
Definition: readfuncs.c:1533
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readMaterial()

static Material* _readMaterial ( void  )
static

Definition at line 2110 of file readfuncs.c.

References READ_DONE, READ_LOCALS_NO_FIELDS, and ReadCommonPlan().

Referenced by parseNodeString().

2111 {
2113 
2114  ReadCommonPlan(&local_node->plan);
2115 
2116  READ_DONE();
2117 }
#define READ_LOCALS_NO_FIELDS(nodeTypeName)
Definition: readfuncs.c:54
static void ReadCommonPlan(Plan *local_node)
Definition: readfuncs.c:1533
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readMergeAppend()

static MergeAppend* _readMergeAppend ( void  )
static

Definition at line 1650 of file readfuncs.c.

References READ_ATTRNUMBER_ARRAY, READ_BOOL_ARRAY, READ_DONE, READ_INT_FIELD, READ_LOCALS, READ_NODE_FIELD, READ_OID_ARRAY, and ReadCommonPlan().

Referenced by parseNodeString().

1651 {
1653 
1654  ReadCommonPlan(&local_node->plan);
1655 
1656  READ_NODE_FIELD(mergeplans);
1657  READ_INT_FIELD(numCols);
1658  READ_ATTRNUMBER_ARRAY(sortColIdx, local_node->numCols);
1659  READ_OID_ARRAY(sortOperators, local_node->numCols);
1660  READ_OID_ARRAY(collations, local_node->numCols);
1661  READ_BOOL_ARRAY(nullsFirst, local_node->numCols);
1662  READ_NODE_FIELD(part_prune_info);
1663 
1664  READ_DONE();
1665 }
#define READ_BOOL_ARRAY(fldname, len)
Definition: readfuncs.c:170
static void ReadCommonPlan(Plan *local_node)
Definition: readfuncs.c:1533
#define READ_OID_ARRAY(fldname, len)
Definition: readfuncs.c:160
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68
#define READ_ATTRNUMBER_ARRAY(fldname, len)
Definition: readfuncs.c:155

◆ _readMergeJoin()

static MergeJoin* _readMergeJoin ( void  )
static

Definition at line 2067 of file readfuncs.c.

References list_length(), READ_BOOL_ARRAY, READ_BOOL_FIELD, READ_DONE, READ_INT_ARRAY, READ_LOCALS, READ_NODE_FIELD, READ_OID_ARRAY, and ReadCommonJoin().

Referenced by parseNodeString().

2068 {
2069  int numCols;
2070 
2072 
2073  ReadCommonJoin(&local_node->join);
2074 
2075  READ_BOOL_FIELD(skip_mark_restore);
2076  READ_NODE_FIELD(mergeclauses);
2077 
2078  numCols = list_length(local_node->mergeclauses);
2079 
2080  READ_OID_ARRAY(mergeFamilies, numCols);
2081  READ_OID_ARRAY(mergeCollations, numCols);
2082  READ_INT_ARRAY(mergeStrategies, numCols);
2083  READ_BOOL_ARRAY(mergeNullsFirst, numCols);
2084 
2085  READ_DONE();
2086 }
#define READ_BOOL_ARRAY(fldname, len)
Definition: readfuncs.c:170
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
#define READ_OID_ARRAY(fldname, len)
Definition: readfuncs.c:160
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
static void ReadCommonJoin(Join *local_node)
Definition: readfuncs.c:2024
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
static int list_length(const List *l)
Definition: pg_list.h:169
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_ARRAY(fldname, len)
Definition: readfuncs.c:165

◆ _readMinMaxExpr()

static MinMaxExpr* _readMinMaxExpr ( void  )
static

Definition at line 1083 of file readfuncs.c.

References generate_unaccent_rules::args, READ_DONE, READ_ENUM_FIELD, READ_LOCALS, READ_LOCATION_FIELD, READ_NODE_FIELD, and READ_OID_FIELD.

Referenced by parseNodeString().

1084 {
1086 
1087  READ_OID_FIELD(minmaxtype);
1088  READ_OID_FIELD(minmaxcollid);
1089  READ_OID_FIELD(inputcollid);
1092  READ_LOCATION_FIELD(location);
1093 
1094  READ_DONE();
1095 }
MinMaxOp
Definition: primnodes.h:1079
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readModifyTable()

static ModifyTable* _readModifyTable ( void  )
static

Definition at line 1598 of file readfuncs.c.

References READ_BITMAPSET_FIELD, READ_BOOL_FIELD, READ_DONE, READ_ENUM_FIELD, READ_INT_FIELD, READ_LOCALS, READ_NODE_FIELD, READ_UINT_FIELD, and ReadCommonPlan().

Referenced by parseNodeString().

1599 {
1601 
1602  ReadCommonPlan(&local_node->plan);
1603 
1604  READ_ENUM_FIELD(operation, CmdType);
1605  READ_BOOL_FIELD(canSetTag);
1606  READ_UINT_FIELD(nominalRelation);
1607  READ_UINT_FIELD(rootRelation);
1608  READ_BOOL_FIELD(partColsUpdated);
1609  READ_NODE_FIELD(resultRelations);
1610  READ_INT_FIELD(resultRelIndex);
1611  READ_INT_FIELD(rootResultRelIndex);
1612  READ_NODE_FIELD(plans);
1613  READ_NODE_FIELD(withCheckOptionLists);
1614  READ_NODE_FIELD(returningLists);
1615  READ_NODE_FIELD(fdwPrivLists);
1616  READ_BITMAPSET_FIELD(fdwDirectModifyPlans);
1617  READ_NODE_FIELD(rowMarks);
1618  READ_INT_FIELD(epqParam);
1619  READ_ENUM_FIELD(onConflictAction, OnConflictAction);
1620  READ_NODE_FIELD(arbiterIndexes);
1621  READ_NODE_FIELD(onConflictSet);
1622  READ_NODE_FIELD(onConflictWhere);
1623  READ_UINT_FIELD(exclRelRTI);
1624  READ_NODE_FIELD(exclRelTlist);
1625 
1626  READ_DONE();
1627 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
static void ReadCommonPlan(Plan *local_node)
Definition: readfuncs.c:1533
#define READ_UINT_FIELD(fldname)
Definition: readfuncs.c:74
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_BITMAPSET_FIELD(fldname)
Definition: readfuncs.c:149
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68
OnConflictAction
Definition: nodes.h:818
CmdType
Definition: nodes.h:668

◆ _readNamedArgExpr()

static NamedArgExpr* _readNamedArgExpr ( void  )
static

Definition at line 706 of file readfuncs.c.

References arg, name, READ_DONE, READ_INT_FIELD, READ_LOCALS, READ_LOCATION_FIELD, READ_NODE_FIELD, and READ_STRING_FIELD.

Referenced by parseNodeString().

707 {
709 
712  READ_INT_FIELD(argnumber);
713  READ_LOCATION_FIELD(location);
714 
715  READ_DONE();
716 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
const char * name
Definition: encode.c:521
void * arg
#define READ_STRING_FIELD(fldname)
Definition: readfuncs.c:123
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readNamedTuplestoreScan()

static NamedTuplestoreScan* _readNamedTuplestoreScan ( void  )
static

Definition at line 1942 of file readfuncs.c.

References READ_DONE, READ_LOCALS, READ_STRING_FIELD, and ReadCommonScan().

Referenced by parseNodeString().

1943 {
1945 
1946  ReadCommonScan(&local_node->scan);
1947 
1948  READ_STRING_FIELD(enrname);
1949 
1950  READ_DONE();
1951 }
static void ReadCommonScan(Scan *local_node)
Definition: readfuncs.c:1723
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_STRING_FIELD(fldname)
Definition: readfuncs.c:123
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readNestLoop()

static NestLoop* _readNestLoop ( void  )
static

Definition at line 2052 of file readfuncs.c.

References READ_DONE, READ_LOCALS, READ_NODE_FIELD, and ReadCommonJoin().

Referenced by parseNodeString().

2053 {
2055 
2056  ReadCommonJoin(&local_node->join);
2057 
2058  READ_NODE_FIELD(nestParams);
2059 
2060  READ_DONE();
2061 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
static void ReadCommonJoin(Join *local_node)
Definition: readfuncs.c:2024
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readNestLoopParam()

static NestLoopParam* _readNestLoopParam ( void  )
static

Definition at line 2348 of file readfuncs.c.

References READ_DONE, READ_INT_FIELD, READ_LOCALS, and READ_NODE_FIELD.

Referenced by parseNodeString().

2349 {
2351 
2352  READ_INT_FIELD(paramno);
2353  READ_NODE_FIELD(paramval);
2354 
2355  READ_DONE();
2356 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readNextValueExpr()

static NextValueExpr* _readNextValueExpr ( void  )
static

Definition at line 1234 of file readfuncs.c.

References READ_DONE, READ_LOCALS, and READ_OID_FIELD.

Referenced by parseNodeString().

1235 {
1237 
1238  READ_OID_FIELD(seqid);
1239  READ_OID_FIELD(typeId);
1240 
1241  READ_DONE();
1242 }
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readNotifyStmt()

static NotifyStmt* _readNotifyStmt ( void  )
static

Definition at line 295 of file readfuncs.c.

References READ_DONE, READ_LOCALS, and READ_STRING_FIELD.

Referenced by parseNodeString().

296 {
298 
299  READ_STRING_FIELD(conditionname);
300  READ_STRING_FIELD(payload);
301 
302  READ_DONE();
303 }
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_STRING_FIELD(fldname)
Definition: readfuncs.c:123
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readNullIfExpr()

static NullIfExpr* _readNullIfExpr ( void  )
static

Definition at line 762 of file readfuncs.c.

References generate_unaccent_rules::args, READ_BOOL_FIELD, READ_DONE, READ_LOCALS, READ_LOCATION_FIELD, READ_NODE_FIELD, and READ_OID_FIELD.

Referenced by parseNodeString().

763 {
765 
766  READ_OID_FIELD(opno);
767  READ_OID_FIELD(opfuncid);
768  READ_OID_FIELD(opresulttype);
769  READ_BOOL_FIELD(opretset);
770  READ_OID_FIELD(opcollid);
771  READ_OID_FIELD(inputcollid);
773  READ_LOCATION_FIELD(location);
774 
775  READ_DONE();
776 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readNullTest()

static NullTest* _readNullTest ( void  )
static

Definition at line 1138 of file readfuncs.c.

References arg, READ_BOOL_FIELD, READ_DONE, READ_ENUM_FIELD, READ_LOCALS, READ_LOCATION_FIELD, and READ_NODE_FIELD.

Referenced by parseNodeString().

1139 {
1141 
1143  READ_ENUM_FIELD(nulltesttype, NullTestType);
1144  READ_BOOL_FIELD(argisrow);
1145  READ_LOCATION_FIELD(location);
1146 
1147  READ_DONE();
1148 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
NullTestType
Definition: primnodes.h:1197
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
void * arg
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readOnConflictExpr()

static OnConflictExpr* _readOnConflictExpr ( void  )
static

Definition at line 1329 of file readfuncs.c.

References generate_unaccent_rules::action, READ_DONE, READ_ENUM_FIELD, READ_INT_FIELD, READ_LOCALS, READ_NODE_FIELD, and READ_OID_FIELD.

Referenced by parseNodeString().

1330 {
1332 
1334  READ_NODE_FIELD(arbiterElems);
1335  READ_NODE_FIELD(arbiterWhere);
1336  READ_OID_FIELD(constraint);
1337  READ_NODE_FIELD(onConflictSet);
1338  READ_NODE_FIELD(onConflictWhere);
1339  READ_INT_FIELD(exclRelIndex);
1340  READ_NODE_FIELD(exclRelTlist);
1341 
1342  READ_DONE();
1343 }
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68
OnConflictAction
Definition: nodes.h:818

◆ _readOpExpr()

static OpExpr* _readOpExpr ( void  )
static

Definition at line 722 of file readfuncs.c.

References generate_unaccent_rules::args, READ_BOOL_FIELD, READ_DONE, READ_LOCALS, READ_LOCATION_FIELD, READ_NODE_FIELD, and READ_OID_FIELD.

Referenced by parseNodeString().

723 {
725 
726  READ_OID_FIELD(opno);
727  READ_OID_FIELD(opfuncid);
728  READ_OID_FIELD(opresulttype);
729  READ_BOOL_FIELD(opretset);
730  READ_OID_FIELD(opcollid);
731  READ_OID_FIELD(inputcollid);
733  READ_LOCATION_FIELD(location);
734 
735  READ_DONE();
736 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readParam()

static Param* _readParam ( void  )
static

Definition at line 579 of file readfuncs.c.

References READ_DONE, READ_ENUM_FIELD, READ_INT_FIELD, READ_LOCALS, READ_LOCATION_FIELD, and READ_OID_FIELD.

Referenced by parseNodeString().

580 {
582 
583  READ_ENUM_FIELD(paramkind, ParamKind);
584  READ_INT_FIELD(paramid);
585  READ_OID_FIELD(paramtype);
586  READ_INT_FIELD(paramtypmod);
587  READ_OID_FIELD(paramcollid);
588  READ_LOCATION_FIELD(location);
589 
590  READ_DONE();
591 }
ParamKind
Definition: primnodes.h:237
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readPartitionBoundSpec()

static PartitionBoundSpec* _readPartitionBoundSpec ( void  )
static

Definition at line 2522 of file readfuncs.c.

References READ_BOOL_FIELD, READ_CHAR_FIELD, READ_DONE, READ_INT_FIELD, READ_LOCALS, READ_LOCATION_FIELD, and READ_NODE_FIELD.

Referenced by parseNodeString().

2523 {
2525 
2526  READ_CHAR_FIELD(strategy);
2527  READ_BOOL_FIELD(is_default);
2528  READ_INT_FIELD(modulus);
2529  READ_INT_FIELD(remainder);
2530  READ_NODE_FIELD(listdatums);
2531  READ_NODE_FIELD(lowerdatums);
2532  READ_NODE_FIELD(upperdatums);
2533  READ_LOCATION_FIELD(location);
2534 
2535  READ_DONE();
2536 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
#define READ_CHAR_FIELD(fldname)
Definition: readfuncs.c:98
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readPartitionedRelPruneInfo()

static PartitionedRelPruneInfo* _readPartitionedRelPruneInfo ( void  )
static

Definition at line 2390 of file readfuncs.c.

References READ_BITMAPSET_FIELD, READ_DONE, READ_INT_ARRAY, READ_INT_FIELD, READ_LOCALS, READ_NODE_FIELD, READ_OID_ARRAY, and READ_UINT_FIELD.

Referenced by parseNodeString().

2391 {
2393 
2394  READ_UINT_FIELD(rtindex);
2395  READ_BITMAPSET_FIELD(present_parts);
2396  READ_INT_FIELD(nparts);
2397  READ_INT_ARRAY(subplan_map, local_node->nparts);
2398  READ_INT_ARRAY(subpart_map, local_node->nparts);
2399  READ_OID_ARRAY(relid_map, local_node->nparts);
2400  READ_NODE_FIELD(initial_pruning_steps);
2401  READ_NODE_FIELD(exec_pruning_steps);
2402  READ_BITMAPSET_FIELD(execparamids);
2403 
2404  READ_DONE();
2405 }
#define READ_OID_ARRAY(fldname, len)
Definition: readfuncs.c:160
#define READ_UINT_FIELD(fldname)
Definition: readfuncs.c:74
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_BITMAPSET_FIELD(fldname)
Definition: readfuncs.c:149
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68
#define READ_INT_ARRAY(fldname, len)
Definition: readfuncs.c:165

◆ _readPartitionPruneInfo()

static PartitionPruneInfo* _readPartitionPruneInfo ( void  )
static

Definition at line 2379 of file readfuncs.c.

References READ_BITMAPSET_FIELD, READ_DONE, READ_LOCALS, and READ_NODE_FIELD.

Referenced by parseNodeString().

2380 {
2382 
2383  READ_NODE_FIELD(prune_infos);
2384  READ_BITMAPSET_FIELD(other_subplans);
2385 
2386  READ_DONE();
2387 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_BITMAPSET_FIELD(fldname)
Definition: readfuncs.c:149
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readPartitionPruneStepCombine()

static PartitionPruneStepCombine* _readPartitionPruneStepCombine ( void  )
static

Definition at line 2422 of file readfuncs.c.

References READ_DONE, READ_ENUM_FIELD, READ_INT_FIELD, READ_LOCALS, and READ_NODE_FIELD.

Referenced by parseNodeString().

2423 {
2425 
2426  READ_INT_FIELD(step.step_id);
2428  READ_NODE_FIELD(source_stepids);
2429 
2430  READ_DONE();
2431 }
PartitionPruneCombineOp
Definition: plannodes.h:1200
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readPartitionPruneStepOp()

static PartitionPruneStepOp* _readPartitionPruneStepOp ( void  )
static

Definition at line 2408 of file readfuncs.c.

References READ_BITMAPSET_FIELD, READ_DONE, READ_INT_FIELD, READ_LOCALS, and READ_NODE_FIELD.

Referenced by parseNodeString().

2409 {
2411 
2412  READ_INT_FIELD(step.step_id);
2413  READ_INT_FIELD(opstrategy);
2414  READ_NODE_FIELD(exprs);
2415  READ_NODE_FIELD(cmpfns);
2416  READ_BITMAPSET_FIELD(nullkeys);
2417 
2418  READ_DONE();
2419 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_BITMAPSET_FIELD(fldname)
Definition: readfuncs.c:149
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readPartitionRangeDatum()

static PartitionRangeDatum* _readPartitionRangeDatum ( void  )
static

Definition at line 2542 of file readfuncs.c.

References READ_DONE, READ_ENUM_FIELD, READ_LOCALS, READ_LOCATION_FIELD, READ_NODE_FIELD, and value.

Referenced by parseNodeString().

2543 {
2545 
2548  READ_LOCATION_FIELD(location);
2549 
2550  READ_DONE();
2551 }
PartitionRangeDatumKind
Definition: parsenodes.h:834
static struct @145 value
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readPlan()

static Plan* _readPlan ( void  )
static

Definition at line 1557 of file readfuncs.c.

References READ_DONE, READ_LOCALS_NO_FIELDS, and ReadCommonPlan().

Referenced by parseNodeString().

1558 {
1560 
1561  ReadCommonPlan(local_node);
1562 
1563  READ_DONE();
1564 }
#define READ_LOCALS_NO_FIELDS(nodeTypeName)
Definition: readfuncs.c:54
static void ReadCommonPlan(Plan *local_node)
Definition: readfuncs.c:1533
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readPlanInvalItem()

static PlanInvalItem* _readPlanInvalItem ( void  )
static

Definition at line 2437 of file readfuncs.c.

References READ_DONE, READ_INT_FIELD, READ_LOCALS, and READ_UINT_FIELD.

Referenced by parseNodeString().

2438 {
2440 
2441  READ_INT_FIELD(cacheId);
2442  READ_UINT_FIELD(hashValue);
2443 
2444  READ_DONE();
2445 }
#define READ_UINT_FIELD(fldname)
Definition: readfuncs.c:74
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readPlannedStmt()

static PlannedStmt* _readPlannedStmt ( void  )
static

Definition at line 1498 of file readfuncs.c.

References READ_BITMAPSET_FIELD, READ_BOOL_FIELD, READ_DONE, READ_ENUM_FIELD, READ_INT_FIELD, READ_LOCALS, READ_LOCATION_FIELD, READ_NODE_FIELD, and READ_UINT64_FIELD.

Referenced by parseNodeString().

1499 {
1501 
1502  READ_ENUM_FIELD(commandType, CmdType);
1503  READ_UINT64_FIELD(queryId);
1504  READ_BOOL_FIELD(hasReturning);
1505  READ_BOOL_FIELD(hasModifyingCTE);
1506  READ_BOOL_FIELD(canSetTag);
1507  READ_BOOL_FIELD(transientPlan);
1508  READ_BOOL_FIELD(dependsOnRole);
1509  READ_BOOL_FIELD(parallelModeNeeded);
1510  READ_INT_FIELD(jitFlags);
1511  READ_NODE_FIELD(planTree);
1512  READ_NODE_FIELD(rtable);
1513  READ_NODE_FIELD(resultRelations);
1514  READ_NODE_FIELD(rootResultRelations);
1515  READ_NODE_FIELD(subplans);
1516  READ_BITMAPSET_FIELD(rewindPlanIDs);
1517  READ_NODE_FIELD(rowMarks);
1518  READ_NODE_FIELD(relationOids);
1519  READ_NODE_FIELD(invalItems);
1520  READ_NODE_FIELD(paramExecTypes);
1521  READ_NODE_FIELD(utilityStmt);
1522  READ_LOCATION_FIELD(stmt_location);
1523  READ_LOCATION_FIELD(stmt_len);
1524 
1525  READ_DONE();
1526 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_UINT64_FIELD(fldname)
Definition: readfuncs.c:80
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_BITMAPSET_FIELD(fldname)
Definition: readfuncs.c:149
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68
CmdType
Definition: nodes.h:668

◆ _readPlanRowMark()

static PlanRowMark* _readPlanRowMark ( void  )
static

Definition at line 2362 of file readfuncs.c.

References READ_BOOL_FIELD, READ_DONE, READ_ENUM_FIELD, READ_INT_FIELD, READ_LOCALS, and READ_UINT_FIELD.

Referenced by parseNodeString().

2363 {
2365 
2366  READ_UINT_FIELD(rti);
2367  READ_UINT_FIELD(prti);
2368  READ_UINT_FIELD(rowmarkId);
2369  READ_ENUM_FIELD(markType, RowMarkType);
2370  READ_INT_FIELD(allMarkTypes);
2372  READ_ENUM_FIELD(waitPolicy, LockWaitPolicy);
2373  READ_BOOL_FIELD(isParent);
2374 
2375  READ_DONE();
2376 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
#define READ_UINT_FIELD(fldname)
Definition: readfuncs.c:74
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
LockClauseStrength
Definition: lockoptions.h:21
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
RowMarkType
Definition: plannodes.h:1003
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68
LockWaitPolicy
Definition: lockoptions.h:36

◆ _readProjectSet()

static ProjectSet* _readProjectSet ( void  )
static

Definition at line 1585 of file readfuncs.c.

References READ_DONE, READ_LOCALS_NO_FIELDS, and ReadCommonPlan().

Referenced by parseNodeString().

1586 {
1588 
1589  ReadCommonPlan(&local_node->plan);
1590 
1591  READ_DONE();
1592 }
#define READ_LOCALS_NO_FIELDS(nodeTypeName)
Definition: readfuncs.c:54
static void ReadCommonPlan(Plan *local_node)
Definition: readfuncs.c:1533
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readQuery()

static Query* _readQuery ( void  )
static

Definition at line 247 of file readfuncs.c.

References READ_BOOL_FIELD, READ_DONE, READ_ENUM_FIELD, READ_INT_FIELD, READ_LOCALS, READ_LOCATION_FIELD, and READ_NODE_FIELD.

Referenced by parseNodeString().

248 {
250 
251  READ_ENUM_FIELD(commandType, CmdType);
252  READ_ENUM_FIELD(querySource, QuerySource);
253  local_node->queryId = UINT64CONST(0); /* not saved in output format */
254  READ_BOOL_FIELD(canSetTag);
255  READ_NODE_FIELD(utilityStmt);
256  READ_INT_FIELD(resultRelation);
257  READ_BOOL_FIELD(hasAggs);
258  READ_BOOL_FIELD(hasWindowFuncs);
259  READ_BOOL_FIELD(hasTargetSRFs);
260  READ_BOOL_FIELD(hasSubLinks);
261  READ_BOOL_FIELD(hasDistinctOn);
262  READ_BOOL_FIELD(hasRecursive);
263  READ_BOOL_FIELD(hasModifyingCTE);
264  READ_BOOL_FIELD(hasForUpdate);
265  READ_BOOL_FIELD(hasRowSecurity);
266  READ_NODE_FIELD(cteList);
267  READ_NODE_FIELD(rtable);
268  READ_NODE_FIELD(jointree);
269  READ_NODE_FIELD(targetList);
270  READ_ENUM_FIELD(override, OverridingKind);
271  READ_NODE_FIELD(onConflict);
272  READ_NODE_FIELD(returningList);
273  READ_NODE_FIELD(groupClause);
274  READ_NODE_FIELD(groupingSets);
275  READ_NODE_FIELD(havingQual);
276  READ_NODE_FIELD(windowClause);
277  READ_NODE_FIELD(distinctClause);
278  READ_NODE_FIELD(sortClause);
279  READ_NODE_FIELD(limitOffset);
280  READ_NODE_FIELD(limitCount);
281  READ_NODE_FIELD(rowMarks);
282  READ_NODE_FIELD(setOperations);
283  READ_NODE_FIELD(constraintDeps);
284  READ_NODE_FIELD(withCheckOptions);
285  READ_LOCATION_FIELD(stmt_location);
286  READ_LOCATION_FIELD(stmt_len);
287 
288  READ_DONE();
289 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
QuerySource
Definition: parsenodes.h:40
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68
CmdType
Definition: nodes.h:668
OverridingKind
Definition: parsenodes.h:32

◆ _readRangeTblEntry()

static RangeTblEntry* _readRangeTblEntry ( void  )
static

Definition at line 1353 of file readfuncs.c.

References TableFunc::colcollations, TableFunc::coltypes, TableFunc::coltypmods, elog, ERROR, functions, READ_BITMAPSET_FIELD, READ_BOOL_FIELD, READ_CHAR_FIELD, READ_DONE, READ_ENUM_FIELD, READ_FLOAT_FIELD, READ_INT_FIELD, READ_LOCALS, READ_NODE_FIELD, READ_OID_FIELD, READ_STRING_FIELD, READ_UINT_FIELD, relkind, RTE_CTE, RTE_FUNCTION, RTE_JOIN, RTE_NAMEDTUPLESTORE, RTE_RELATION, RTE_RESULT, RTE_SUBQUERY, RTE_TABLEFUNC, and RTE_VALUES.

Referenced by parseNodeString().

1354 {
1356 
1357  /* put alias + eref first to make dump more legible */
1358  READ_NODE_FIELD(alias);
1359  READ_NODE_FIELD(eref);
1360  READ_ENUM_FIELD(rtekind, RTEKind);
1361 
1362  switch (local_node->rtekind)
1363  {
1364  case RTE_RELATION:
1365  READ_OID_FIELD(relid);
1367  READ_INT_FIELD(rellockmode);
1368  READ_NODE_FIELD(tablesample);
1369  break;
1370  case RTE_SUBQUERY:
1371  READ_NODE_FIELD(subquery);
1372  READ_BOOL_FIELD(security_barrier);
1373  break;
1374  case RTE_JOIN:
1375  READ_ENUM_FIELD(jointype, JoinType);
1376  READ_NODE_FIELD(joinaliasvars);
1377  break;
1378  case RTE_FUNCTION:
1380  READ_BOOL_FIELD(funcordinality);
1381  break;
1382  case RTE_TABLEFUNC:
1383  READ_NODE_FIELD(tablefunc);
1384  /* The RTE must have a copy of the column type info, if any */
1385  if (local_node->tablefunc)
1386  {
1387  TableFunc *tf = local_node->tablefunc;
1388 
1389  local_node->coltypes = tf->coltypes;
1390  local_node->coltypmods = tf->coltypmods;
1391  local_node->colcollations = tf->colcollations;
1392  }
1393  break;
1394  case RTE_VALUES:
1395  READ_NODE_FIELD(values_lists);
1396  READ_NODE_FIELD(coltypes);
1397  READ_NODE_FIELD(coltypmods);
1398  READ_NODE_FIELD(colcollations);
1399  break;
1400  case RTE_CTE:
1401  READ_STRING_FIELD(ctename);
1402  READ_UINT_FIELD(ctelevelsup);
1403  READ_BOOL_FIELD(self_reference);
1404  READ_NODE_FIELD(coltypes);
1405  READ_NODE_FIELD(coltypmods);
1406  READ_NODE_FIELD(colcollations);
1407  break;
1408  case RTE_NAMEDTUPLESTORE:
1409  READ_STRING_FIELD(enrname);
1410  READ_FLOAT_FIELD(enrtuples);
1411  READ_OID_FIELD(relid);
1412  READ_NODE_FIELD(coltypes);
1413  READ_NODE_FIELD(coltypmods);
1414  READ_NODE_FIELD(colcollations);
1415  break;
1416  case RTE_RESULT:
1417  /* no extra fields */
1418  break;
1419  default:
1420  elog(ERROR, "unrecognized RTE kind: %d",
1421  (int) local_node->rtekind);
1422  break;
1423  }
1424 
1425  READ_BOOL_FIELD(lateral);
1426  READ_BOOL_FIELD(inh);
1427  READ_BOOL_FIELD(inFromCl);
1428  READ_UINT_FIELD(requiredPerms);
1429  READ_OID_FIELD(checkAsUser);
1430  READ_BITMAPSET_FIELD(selectedCols);
1431  READ_BITMAPSET_FIELD(insertedCols);
1432  READ_BITMAPSET_FIELD(updatedCols);
1433  READ_BITMAPSET_FIELD(extraUpdatedCols);
1434  READ_NODE_FIELD(securityQuals);
1435 
1436  READ_DONE();
1437 }
List * coltypmods
Definition: primnodes.h:91
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
char relkind
Definition: pg_class.h:81
List * colcollations
Definition: primnodes.h:92
JoinType
Definition: nodes.h:692
#define ERROR
Definition: elog.h:43
#define READ_FLOAT_FIELD(fldname)
Definition: readfuncs.c:111
RTEKind
Definition: parsenodes.h:955
#define READ_CHAR_FIELD(fldname)
Definition: readfuncs.c:98
#define READ_UINT_FIELD(fldname)
Definition: readfuncs.c:74
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
List * coltypes
Definition: primnodes.h:90
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
static const struct fns functions
Definition: regcomp.c:298
#define READ_BITMAPSET_FIELD(fldname)
Definition: readfuncs.c:149
#define elog(elevel,...)
Definition: elog.h:226
#define READ_STRING_FIELD(fldname)
Definition: readfuncs.c:123
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readRangeTblFunction()

static RangeTblFunction* _readRangeTblFunction ( void  )
static

Definition at line 1443 of file readfuncs.c.

References READ_BITMAPSET_FIELD, READ_DONE, READ_INT_FIELD, READ_LOCALS, and READ_NODE_FIELD.

Referenced by parseNodeString().

1444 {
1446 
1447  READ_NODE_FIELD(funcexpr);
1448  READ_INT_FIELD(funccolcount);
1449  READ_NODE_FIELD(funccolnames);
1450  READ_NODE_FIELD(funccoltypes);
1451  READ_NODE_FIELD(funccoltypmods);
1452  READ_NODE_FIELD(funccolcollations);
1453  READ_BITMAPSET_FIELD(funcparams);
1454 
1455  READ_DONE();
1456 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_BITMAPSET_FIELD(fldname)
Definition: readfuncs.c:149
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readRangeTblRef()

static RangeTblRef* _readRangeTblRef ( void  )
static

Definition at line 1282 of file readfuncs.c.

References READ_DONE, READ_INT_FIELD, and READ_LOCALS.

Referenced by parseNodeString().

1283 {
1285 
1286  READ_INT_FIELD(rtindex);
1287 
1288  READ_DONE();
1289 }
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readRangeVar()

static RangeVar* _readRangeVar ( void  )
static

Definition at line 471 of file readfuncs.c.

References READ_BOOL_FIELD, READ_CHAR_FIELD, READ_DONE, READ_LOCALS, READ_LOCATION_FIELD, READ_NODE_FIELD, READ_STRING_FIELD, relname, and relpersistence.

Referenced by parseNodeString().

472 {
474 
475  local_node->catalogname = NULL; /* not currently saved in output format */
476 
477  READ_STRING_FIELD(schemaname);
479  READ_BOOL_FIELD(inh);
481  READ_NODE_FIELD(alias);
482  READ_LOCATION_FIELD(location);
483 
484  READ_DONE();
485 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
NameData relname
Definition: pg_class.h:35
char relpersistence
Definition: pg_class.h:78
#define READ_CHAR_FIELD(fldname)
Definition: readfuncs.c:98
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_STRING_FIELD(fldname)
Definition: readfuncs.c:123
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readRecursiveUnion()

static RecursiveUnion* _readRecursiveUnion ( void  )
static

Definition at line 1671 of file readfuncs.c.

References READ_ATTRNUMBER_ARRAY, READ_DONE, READ_INT_FIELD, READ_LOCALS, READ_LONG_FIELD, READ_OID_ARRAY, and ReadCommonPlan().

Referenced by parseNodeString().

1672 {
1674 
1675  ReadCommonPlan(&local_node->plan);
1676 
1677  READ_INT_FIELD(wtParam);
1678  READ_INT_FIELD(numCols);
1679  READ_ATTRNUMBER_ARRAY(dupColIdx, local_node->numCols);
1680  READ_OID_ARRAY(dupOperators, local_node->numCols);
1681  READ_OID_ARRAY(dupCollations, local_node->numCols);
1682  READ_LONG_FIELD(numGroups);
1683 
1684  READ_DONE();
1685 }
#define READ_LONG_FIELD(fldname)
Definition: readfuncs.c:86
static void ReadCommonPlan(Plan *local_node)
Definition: readfuncs.c:1533
#define READ_OID_ARRAY(fldname, len)
Definition: readfuncs.c:160
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68
#define READ_ATTRNUMBER_ARRAY(fldname, len)
Definition: readfuncs.c:155

◆ _readRelabelType()

static RelabelType* _readRelabelType ( void  )
static

Definition at line 881 of file readfuncs.c.

References arg, READ_DONE, READ_ENUM_FIELD, READ_INT_FIELD, READ_LOCALS, READ_LOCATION_FIELD, READ_NODE_FIELD, and READ_OID_FIELD.

Referenced by parseNodeString().

882 {
884 
886  READ_OID_FIELD(resulttype);
887  READ_INT_FIELD(resulttypmod);
888  READ_OID_FIELD(resultcollid);
889  READ_ENUM_FIELD(relabelformat, CoercionForm);
890  READ_LOCATION_FIELD(location);
891 
892  READ_DONE();
893 }
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
void * arg
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68
CoercionForm
Definition: primnodes.h:442

◆ _readResult()

static Result* _readResult ( void  )
static

Definition at line 1570 of file readfuncs.c.

References READ_DONE, READ_LOCALS, READ_NODE_FIELD, and ReadCommonPlan().

Referenced by parseNodeString().

1571 {
1573 
1574  ReadCommonPlan(&local_node->plan);
1575 
1576  READ_NODE_FIELD(resconstantqual);
1577 
1578  READ_DONE();
1579 }
static void ReadCommonPlan(Plan *local_node)
Definition: readfuncs.c:1533
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readRowCompareExpr()

static RowCompareExpr* _readRowCompareExpr ( void  )
static

Definition at line 1049 of file readfuncs.c.

References READ_DONE, READ_ENUM_FIELD, READ_LOCALS, and READ_NODE_FIELD.

Referenced by parseNodeString().

1050 {
1052 
1054  READ_NODE_FIELD(opnos);
1055  READ_NODE_FIELD(opfamilies);
1056  READ_NODE_FIELD(inputcollids);
1057  READ_NODE_FIELD(largs);
1058  READ_NODE_FIELD(rargs);
1059 
1060  READ_DONE();
1061 }
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
RowCompareType
Definition: primnodes.h:1042
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readRowExpr()

static RowExpr* _readRowExpr ( void  )
static

Definition at line 1032 of file readfuncs.c.

References generate_unaccent_rules::args, READ_DONE, READ_ENUM_FIELD, READ_LOCALS, READ_LOCATION_FIELD, READ_NODE_FIELD, and READ_OID_FIELD.

Referenced by parseNodeString().

1033 {
1035 
1037  READ_OID_FIELD(row_typeid);
1038  READ_ENUM_FIELD(row_format, CoercionForm);
1039  READ_NODE_FIELD(colnames);
1040  READ_LOCATION_FIELD(location);
1041 
1042  READ_DONE();
1043 }
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175
CoercionForm
Definition: primnodes.h:442

◆ _readRowMarkClause()

static RowMarkClause* _readRowMarkClause ( void  )
static

Definition at line 399 of file readfuncs.c.

References READ_BOOL_FIELD, READ_DONE, READ_ENUM_FIELD, READ_LOCALS, and READ_UINT_FIELD.

Referenced by parseNodeString().

400 {
402 
403  READ_UINT_FIELD(rti);
405  READ_ENUM_FIELD(waitPolicy, LockWaitPolicy);
406  READ_BOOL_FIELD(pushedDown);
407 
408  READ_DONE();
409 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
#define READ_UINT_FIELD(fldname)
Definition: readfuncs.c:74
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
LockClauseStrength
Definition: lockoptions.h:21
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175
LockWaitPolicy
Definition: lockoptions.h:36

◆ _readSampleScan()

static SampleScan* _readSampleScan ( void  )
static

Definition at line 1762 of file readfuncs.c.

References READ_DONE, READ_LOCALS, READ_NODE_FIELD, and ReadCommonScan().

Referenced by parseNodeString().

1763 {
1765 
1766  ReadCommonScan(&local_node->scan);
1767 
1768  READ_NODE_FIELD(tablesample);
1769 
1770  READ_DONE();
1771 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
static void ReadCommonScan(Scan *local_node)
Definition: readfuncs.c:1723
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readScalarArrayOpExpr()

static ScalarArrayOpExpr* _readScalarArrayOpExpr ( void  )
static

Definition at line 782 of file readfuncs.c.

References generate_unaccent_rules::args, READ_BOOL_FIELD, READ_DONE, READ_LOCALS, READ_LOCATION_FIELD, READ_NODE_FIELD, and READ_OID_FIELD.

Referenced by parseNodeString().

783 {
785 
786  READ_OID_FIELD(opno);
787  READ_OID_FIELD(opfuncid);
788  READ_BOOL_FIELD(useOr);
789  READ_OID_FIELD(inputcollid);
791  READ_LOCATION_FIELD(location);
792 
793  READ_DONE();
794 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readScan()

static Scan* _readScan ( void  )
static

Definition at line 1736 of file readfuncs.c.

References READ_DONE, READ_LOCALS_NO_FIELDS, and ReadCommonScan().

Referenced by parseNodeString().

1737 {
1739 
1740  ReadCommonScan(local_node);
1741 
1742  READ_DONE();
1743 }
#define READ_LOCALS_NO_FIELDS(nodeTypeName)
Definition: readfuncs.c:54
static void ReadCommonScan(Scan *local_node)
Definition: readfuncs.c:1723
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readSeqScan()

static SeqScan* _readSeqScan ( void  )
static

Definition at line 1749 of file readfuncs.c.

References READ_DONE, READ_LOCALS_NO_FIELDS, and ReadCommonScan().

Referenced by parseNodeString().

1750 {
1752 
1753  ReadCommonScan(local_node);
1754 
1755  READ_DONE();
1756 }
#define READ_LOCALS_NO_FIELDS(nodeTypeName)
Definition: readfuncs.c:54
static void ReadCommonScan(Scan *local_node)
Definition: readfuncs.c:1723
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readSetOp()

static SetOp* _readSetOp ( void  )
static

Definition at line 2293 of file readfuncs.c.

References READ_ATTRNUMBER_ARRAY, READ_DONE, READ_ENUM_FIELD, READ_INT_FIELD, READ_LOCALS, READ_LONG_FIELD, READ_OID_ARRAY, and ReadCommonPlan().

Referenced by parseNodeString().

2294 {
2295  READ_LOCALS(SetOp);
2296 
2297  ReadCommonPlan(&local_node->plan);
2298 
2299  READ_ENUM_FIELD(cmd, SetOpCmd);
2300  READ_ENUM_FIELD(strategy, SetOpStrategy);
2301  READ_INT_FIELD(numCols);
2302  READ_ATTRNUMBER_ARRAY(dupColIdx, local_node->numCols);
2303  READ_OID_ARRAY(dupOperators, local_node->numCols);
2304  READ_OID_ARRAY(dupCollations, local_node->numCols);
2305  READ_INT_FIELD(flagColIdx);
2306  READ_INT_FIELD(firstFlag);
2307  READ_LONG_FIELD(numGroups);
2308 
2309  READ_DONE();
2310 }
#define READ_LONG_FIELD(fldname)
Definition: readfuncs.c:86
SetOpStrategy
Definition: nodes.h:806
static void ReadCommonPlan(Plan *local_node)
Definition: readfuncs.c:1533
#define READ_OID_ARRAY(fldname, len)
Definition: readfuncs.c:160
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
SetOpCmd
Definition: nodes.h:798
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68
#define READ_ATTRNUMBER_ARRAY(fldname, len)
Definition: readfuncs.c:155

◆ _readSetOperationStmt()

static SetOperationStmt* _readSetOperationStmt ( void  )
static

Definition at line 438 of file readfuncs.c.

References READ_BOOL_FIELD, READ_DONE, READ_ENUM_FIELD, READ_LOCALS, and READ_NODE_FIELD.

Referenced by parseNodeString().

439 {
441 
443  READ_BOOL_FIELD(all);
444  READ_NODE_FIELD(larg);
445  READ_NODE_FIELD(rarg);
446  READ_NODE_FIELD(colTypes);
447  READ_NODE_FIELD(colTypmods);
448  READ_NODE_FIELD(colCollations);
449  READ_NODE_FIELD(groupClauses);
450 
451  READ_DONE();
452 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
SetOperation
Definition: parsenodes.h:1556
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readSetToDefault()

static SetToDefault* _readSetToDefault ( void  )
static

Definition at line 1203 of file readfuncs.c.

References READ_DONE, READ_INT_FIELD, READ_LOCALS, READ_LOCATION_FIELD, and READ_OID_FIELD.

Referenced by parseNodeString().

1204 {
1206 
1207  READ_OID_FIELD(typeId);
1208  READ_INT_FIELD(typeMod);
1209  READ_OID_FIELD(collation);
1210  READ_LOCATION_FIELD(location);
1211 
1212  READ_DONE();
1213 }
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readSort()

static Sort* _readSort ( void  )
static

Definition at line 2123 of file readfuncs.c.

References READ_ATTRNUMBER_ARRAY, READ_BOOL_ARRAY, READ_DONE, READ_INT_FIELD, READ_LOCALS, READ_OID_ARRAY, and ReadCommonPlan().

Referenced by parseNodeString().

2124 {
2125  READ_LOCALS(Sort);
2126 
2127  ReadCommonPlan(&local_node->plan);
2128 
2129  READ_INT_FIELD(numCols);
2130  READ_ATTRNUMBER_ARRAY(sortColIdx, local_node->numCols);
2131  READ_OID_ARRAY(sortOperators, local_node->numCols);
2132  READ_OID_ARRAY(collations, local_node->numCols);
2133  READ_BOOL_ARRAY(nullsFirst, local_node->numCols);
2134 
2135  READ_DONE();
2136 }
#define READ_BOOL_ARRAY(fldname, len)
Definition: readfuncs.c:170
static void ReadCommonPlan(Plan *local_node)
Definition: readfuncs.c:1533
#define READ_OID_ARRAY(fldname, len)
Definition: readfuncs.c:160
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68
#define READ_ATTRNUMBER_ARRAY(fldname, len)
Definition: readfuncs.c:155

◆ _readSortGroupClause()

static SortGroupClause* _readSortGroupClause ( void  )
static

Definition at line 341 of file readfuncs.c.

References READ_BOOL_FIELD, READ_DONE, READ_LOCALS, READ_OID_FIELD, and READ_UINT_FIELD.

Referenced by parseNodeString().

342 {
344 
345  READ_UINT_FIELD(tleSortGroupRef);
346  READ_OID_FIELD(eqop);
347  READ_OID_FIELD(sortop);
348  READ_BOOL_FIELD(nulls_first);
349  READ_BOOL_FIELD(hashable);
350 
351  READ_DONE();
352 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
#define READ_UINT_FIELD(fldname)
Definition: readfuncs.c:74
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readSQLValueFunction()

static SQLValueFunction* _readSQLValueFunction ( void  )
static

Definition at line 1101 of file readfuncs.c.

References READ_DONE, READ_ENUM_FIELD, READ_INT_FIELD, READ_LOCALS, READ_LOCATION_FIELD, READ_OID_FIELD, and generate_unaccent_rules::type.

Referenced by parseNodeString().

1102 {
1104 
1107  READ_INT_FIELD(typmod);
1108  READ_LOCATION_FIELD(location);
1109 
1110  READ_DONE();
1111 }
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
SQLValueFunctionOp
Definition: primnodes.h:1107
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readSubLink()

static SubLink* _readSubLink ( void  )
static

Definition at line 826 of file readfuncs.c.

References READ_DONE, READ_ENUM_FIELD, READ_INT_FIELD, READ_LOCALS, READ_LOCATION_FIELD, and READ_NODE_FIELD.

Referenced by parseNodeString().

827 {
829 
830  READ_ENUM_FIELD(subLinkType, SubLinkType);
831  READ_INT_FIELD(subLinkId);
832  READ_NODE_FIELD(testexpr);
833  READ_NODE_FIELD(operName);
834  READ_NODE_FIELD(subselect);
835  READ_LOCATION_FIELD(location);
836 
837  READ_DONE();
838 }
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
SubLinkType
Definition: primnodes.h:624
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readSubPlan()

static SubPlan* _readSubPlan ( void  )
static

Definition at line 2451 of file readfuncs.c.

References generate_unaccent_rules::args, READ_BOOL_FIELD, READ_DONE, READ_ENUM_FIELD, READ_FLOAT_FIELD, READ_INT_FIELD, READ_LOCALS, READ_NODE_FIELD, READ_OID_FIELD, and READ_STRING_FIELD.

Referenced by parseNodeString().

2452 {
2454 
2455  READ_ENUM_FIELD(subLinkType, SubLinkType);
2456  READ_NODE_FIELD(testexpr);
2457  READ_NODE_FIELD(paramIds);
2458  READ_INT_FIELD(plan_id);
2459  READ_STRING_FIELD(plan_name);
2460  READ_OID_FIELD(firstColType);
2461  READ_INT_FIELD(firstColTypmod);
2462  READ_OID_FIELD(firstColCollation);
2463  READ_BOOL_FIELD(useHashTable);
2464  READ_BOOL_FIELD(unknownEqFalse);
2465  READ_BOOL_FIELD(parallel_safe);
2466  READ_NODE_FIELD(setParam);
2467  READ_NODE_FIELD(parParam);
2469  READ_FLOAT_FIELD(startup_cost);
2470  READ_FLOAT_FIELD(per_call_cost);
2471 
2472  READ_DONE();
2473 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
#define READ_FLOAT_FIELD(fldname)
Definition: readfuncs.c:111
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
SubLinkType
Definition: primnodes.h:624
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_STRING_FIELD(fldname)
Definition: readfuncs.c:123
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readSubqueryScan()

static SubqueryScan* _readSubqueryScan ( void  )
static

Definition at line 1865 of file readfuncs.c.

References READ_DONE, READ_LOCALS, READ_NODE_FIELD, and ReadCommonScan().

Referenced by parseNodeString().

1866 {
1868 
1869  ReadCommonScan(&local_node->scan);
1870 
1871  READ_NODE_FIELD(subplan);
1872 
1873  READ_DONE();
1874 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
static void ReadCommonScan(Scan *local_node)
Definition: readfuncs.c:1723
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readSubscriptingRef()

static SubscriptingRef* _readSubscriptingRef ( void  )
static

Definition at line 665 of file readfuncs.c.

References READ_DONE, READ_INT_FIELD, READ_LOCALS, READ_NODE_FIELD, and READ_OID_FIELD.

Referenced by parseNodeString().

666 {
668 
669  READ_OID_FIELD(refcontainertype);
670  READ_OID_FIELD(refelemtype);
671  READ_INT_FIELD(reftypmod);
672  READ_OID_FIELD(refcollid);
673  READ_NODE_FIELD(refupperindexpr);
674  READ_NODE_FIELD(reflowerindexpr);
675  READ_NODE_FIELD(refexpr);
676  READ_NODE_FIELD(refassgnexpr);
677 
678  READ_DONE();
679 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readTableFunc()

static TableFunc* _readTableFunc ( void  )
static

Definition at line 491 of file readfuncs.c.

References READ_BITMAPSET_FIELD, READ_DONE, READ_INT_FIELD, READ_LOCALS, READ_LOCATION_FIELD, and READ_NODE_FIELD.

Referenced by parseNodeString().

492 {
494 
495  READ_NODE_FIELD(ns_uris);
496  READ_NODE_FIELD(ns_names);
497  READ_NODE_FIELD(docexpr);
498  READ_NODE_FIELD(rowexpr);
499  READ_NODE_FIELD(colnames);
500  READ_NODE_FIELD(coltypes);
501  READ_NODE_FIELD(coltypmods);
502  READ_NODE_FIELD(colcollations);
503  READ_NODE_FIELD(colexprs);
504  READ_NODE_FIELD(coldefexprs);
505  READ_BITMAPSET_FIELD(notnulls);
506  READ_INT_FIELD(ordinalitycol);
507  READ_LOCATION_FIELD(location);
508 
509  READ_DONE();
510 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_BITMAPSET_FIELD(fldname)
Definition: readfuncs.c:149
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readTableFuncScan()

static TableFuncScan* _readTableFuncScan ( void  )
static

Definition at line 1911 of file readfuncs.c.

References READ_DONE, READ_LOCALS, READ_NODE_FIELD, and ReadCommonScan().

Referenced by parseNodeString().

1912 {
1914 
1915  ReadCommonScan(&local_node->scan);
1916 
1917  READ_NODE_FIELD(tablefunc);
1918 
1919  READ_DONE();
1920 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
static void ReadCommonScan(Scan *local_node)
Definition: readfuncs.c:1723
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readTableSampleClause()

static TableSampleClause* _readTableSampleClause ( void  )
static

Definition at line 1462 of file readfuncs.c.

References generate_unaccent_rules::args, READ_DONE, READ_LOCALS, READ_NODE_FIELD, and READ_OID_FIELD.

Referenced by parseNodeString().

1463 {
1465 
1466  READ_OID_FIELD(tsmhandler);
1468  READ_NODE_FIELD(repeatable);
1469 
1470  READ_DONE();
1471 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readTargetEntry()

static TargetEntry* _readTargetEntry ( void  )
static

Definition at line 1263 of file readfuncs.c.

References READ_BOOL_FIELD, READ_DONE, READ_INT_FIELD, READ_LOCALS, READ_NODE_FIELD, READ_OID_FIELD, READ_STRING_FIELD, and READ_UINT_FIELD.

Referenced by parseNodeString().

1264 {
1266 
1267  READ_NODE_FIELD(expr);
1268  READ_INT_FIELD(resno);
1269  READ_STRING_FIELD(resname);
1270  READ_UINT_FIELD(ressortgroupref);
1271  READ_OID_FIELD(resorigtbl);
1272  READ_INT_FIELD(resorigcol);
1273  READ_BOOL_FIELD(resjunk);
1274 
1275  READ_DONE();
1276 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
#define READ_UINT_FIELD(fldname)
Definition: readfuncs.c:74
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_STRING_FIELD(fldname)
Definition: readfuncs.c:123
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readTidScan()

static TidScan* _readTidScan ( void  )
static

Definition at line 1850 of file readfuncs.c.

References READ_DONE, READ_LOCALS, READ_NODE_FIELD, and ReadCommonScan().

Referenced by parseNodeString().

1851 {
1853 
1854  ReadCommonScan(&local_node->scan);
1855 
1856  READ_NODE_FIELD(tidquals);
1857 
1858  READ_DONE();
1859 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
static void ReadCommonScan(Scan *local_node)
Definition: readfuncs.c:1723
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readUnique()

static Unique* _readUnique ( void  )
static

Definition at line 2215 of file readfuncs.c.

References READ_ATTRNUMBER_ARRAY, READ_DONE, READ_INT_FIELD, READ_LOCALS, READ_OID_ARRAY, and ReadCommonPlan().

Referenced by parseNodeString().

2216 {
2218 
2219  ReadCommonPlan(&local_node->plan);
2220 
2221  READ_INT_FIELD(numCols);
2222  READ_ATTRNUMBER_ARRAY(uniqColIdx, local_node->numCols);
2223  READ_OID_ARRAY(uniqOperators, local_node->numCols);
2224  READ_OID_ARRAY(uniqCollations, local_node->numCols);
2225 
2226  READ_DONE();
2227 }
static void ReadCommonPlan(Plan *local_node)
Definition: readfuncs.c:1533
#define READ_OID_ARRAY(fldname, len)
Definition: readfuncs.c:160
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68
#define READ_ATTRNUMBER_ARRAY(fldname, len)
Definition: readfuncs.c:155

◆ _readValuesScan()

static ValuesScan* _readValuesScan ( void  )
static

Definition at line 1896 of file readfuncs.c.

References READ_DONE, READ_LOCALS, READ_NODE_FIELD, and ReadCommonScan().

Referenced by parseNodeString().

1897 {
1899 
1900  ReadCommonScan(&local_node->scan);
1901 
1902  READ_NODE_FIELD(values_lists);
1903 
1904  READ_DONE();
1905 }
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
static void ReadCommonScan(Scan *local_node)
Definition: readfuncs.c:1723
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readVar()

static Var* _readVar ( void  )
static

Definition at line 533 of file readfuncs.c.

References READ_DONE, READ_INT_FIELD, READ_LOCALS, READ_LOCATION_FIELD, READ_OID_FIELD, and READ_UINT_FIELD.

Referenced by parseNodeString().

534 {
535  READ_LOCALS(Var);
536 
537  READ_UINT_FIELD(varno);
538  READ_INT_FIELD(varattno);
539  READ_OID_FIELD(vartype);
540  READ_INT_FIELD(vartypmod);
541  READ_OID_FIELD(varcollid);
542  READ_UINT_FIELD(varlevelsup);
543  READ_UINT_FIELD(varnoold);
544  READ_INT_FIELD(varoattno);
545  READ_LOCATION_FIELD(location);
546 
547  READ_DONE();
548 }
Definition: primnodes.h:167
#define READ_UINT_FIELD(fldname)
Definition: readfuncs.c:74
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readWindowAgg()

static WindowAgg* _readWindowAgg ( void  )
static

Definition at line 2184 of file readfuncs.c.

References READ_ATTRNUMBER_ARRAY, READ_BOOL_FIELD, READ_DONE, READ_INT_FIELD, READ_LOCALS, READ_NODE_FIELD, READ_OID_ARRAY, READ_OID_FIELD, READ_UINT_FIELD, and ReadCommonPlan().

Referenced by parseNodeString().

2185 {
2187 
2188  ReadCommonPlan(&local_node->plan);
2189 
2190  READ_UINT_FIELD(winref);
2191  READ_INT_FIELD(partNumCols);
2192  READ_ATTRNUMBER_ARRAY(partColIdx, local_node->partNumCols);
2193  READ_OID_ARRAY(partOperators, local_node->partNumCols);
2194  READ_OID_ARRAY(partCollations, local_node->partNumCols);
2195  READ_INT_FIELD(ordNumCols);
2196  READ_ATTRNUMBER_ARRAY(ordColIdx, local_node->ordNumCols);
2197  READ_OID_ARRAY(ordOperators, local_node->ordNumCols);
2198  READ_OID_ARRAY(ordCollations, local_node->ordNumCols);
2199  READ_INT_FIELD(frameOptions);
2200  READ_NODE_FIELD(startOffset);
2201  READ_NODE_FIELD(endOffset);
2202  READ_OID_FIELD(startInRangeFunc);
2203  READ_OID_FIELD(endInRangeFunc);
2204  READ_OID_FIELD(inRangeColl);
2205  READ_BOOL_FIELD(inRangeAsc);
2206  READ_BOOL_FIELD(inRangeNullsFirst);
2207 
2208  READ_DONE();
2209 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
static void ReadCommonPlan(Plan *local_node)
Definition: readfuncs.c:1533
#define READ_OID_ARRAY(fldname, len)
Definition: readfuncs.c:160
#define READ_UINT_FIELD(fldname)
Definition: readfuncs.c:74
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68
#define READ_ATTRNUMBER_ARRAY(fldname, len)
Definition: readfuncs.c:155

◆ _readWindowClause()

static WindowClause* _readWindowClause ( void  )
static

Definition at line 373 of file readfuncs.c.

References name, READ_BOOL_FIELD, READ_DONE, READ_INT_FIELD, READ_LOCALS, READ_NODE_FIELD, READ_OID_FIELD, READ_STRING_FIELD, and READ_UINT_FIELD.

Referenced by parseNodeString().

374 {
376 
378  READ_STRING_FIELD(refname);
379  READ_NODE_FIELD(partitionClause);
380  READ_NODE_FIELD(orderClause);
381  READ_INT_FIELD(frameOptions);
382  READ_NODE_FIELD(startOffset);
383  READ_NODE_FIELD(endOffset);
384  READ_OID_FIELD(startInRangeFunc);
385  READ_OID_FIELD(endInRangeFunc);
386  READ_OID_FIELD(inRangeColl);
387  READ_BOOL_FIELD(inRangeAsc);
388  READ_BOOL_FIELD(inRangeNullsFirst);
389  READ_UINT_FIELD(winref);
390  READ_BOOL_FIELD(copiedOrder);
391 
392  READ_DONE();
393 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
#define READ_UINT_FIELD(fldname)
Definition: readfuncs.c:74
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
const char * name
Definition: encode.c:521
#define READ_STRING_FIELD(fldname)
Definition: readfuncs.c:123
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readWindowFunc()

static WindowFunc* _readWindowFunc ( void  )
static

Definition at line 643 of file readfuncs.c.

References generate_unaccent_rules::args, READ_BOOL_FIELD, READ_DONE, READ_LOCALS, READ_LOCATION_FIELD, READ_NODE_FIELD, READ_OID_FIELD, and READ_UINT_FIELD.

Referenced by parseNodeString().

644 {
646 
647  READ_OID_FIELD(winfnoid);
648  READ_OID_FIELD(wintype);
649  READ_OID_FIELD(wincollid);
650  READ_OID_FIELD(inputcollid);
652  READ_NODE_FIELD(aggfilter);
653  READ_UINT_FIELD(winref);
654  READ_BOOL_FIELD(winstar);
655  READ_BOOL_FIELD(winagg);
656  READ_LOCATION_FIELD(location);
657 
658  READ_DONE();
659 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
#define READ_UINT_FIELD(fldname)
Definition: readfuncs.c:74
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readWithCheckOption()

static WithCheckOption* _readWithCheckOption ( void  )
static

Definition at line 324 of file readfuncs.c.

References READ_BOOL_FIELD, READ_DONE, READ_ENUM_FIELD, READ_LOCALS, READ_NODE_FIELD, READ_STRING_FIELD, and relname.

Referenced by parseNodeString().

325 {
327 
328  READ_ENUM_FIELD(kind, WCOKind);
330  READ_STRING_FIELD(polname);
331  READ_NODE_FIELD(qual);
332  READ_BOOL_FIELD(cascaded);
333 
334  READ_DONE();
335 }
#define READ_BOOL_FIELD(fldname)
Definition: readfuncs.c:117
NameData relname
Definition: pg_class.h:35
WCOKind
Definition: parsenodes.h:1155
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_STRING_FIELD(fldname)
Definition: readfuncs.c:123
#define READ_DONE()
Definition: readfuncs.c:175

◆ _readWorkTableScan()

static WorkTableScan* _readWorkTableScan ( void  )
static

Definition at line 1957 of file readfuncs.c.

References READ_DONE, READ_INT_FIELD, READ_LOCALS, and ReadCommonScan().

Referenced by parseNodeString().

1958 {
1960 
1961  ReadCommonScan(&local_node->scan);
1962 
1963  READ_INT_FIELD(wtParam);
1964 
1965  READ_DONE();
1966 }
static void ReadCommonScan(Scan *local_node)
Definition: readfuncs.c:1723
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ _readXmlExpr()

static XmlExpr* _readXmlExpr ( void  )
static

Definition at line 1117 of file readfuncs.c.

References generate_unaccent_rules::args, name, READ_DONE, READ_ENUM_FIELD, READ_INT_FIELD, READ_LOCALS, READ_LOCATION_FIELD, READ_NODE_FIELD, READ_OID_FIELD, READ_STRING_FIELD, generate_unaccent_rules::type, and xmloption.

Referenced by parseNodeString().

1118 {
1120 
1123  READ_NODE_FIELD(named_args);
1124  READ_NODE_FIELD(arg_names);
1128  READ_INT_FIELD(typmod);
1129  READ_LOCATION_FIELD(location);
1130 
1131  READ_DONE();
1132 }
XmlExprOp
Definition: primnodes.h:1146
#define READ_ENUM_FIELD(fldname, enumtype)
Definition: readfuncs.c:105
#define READ_NODE_FIELD(fldname)
Definition: readfuncs.c:143
#define READ_LOCATION_FIELD(fldname)
Definition: readfuncs.c:135
#define READ_LOCALS(nodeTypeName)
Definition: readfuncs.c:63
XmlOptionType
Definition: primnodes.h:1158
#define READ_OID_FIELD(fldname)
Definition: readfuncs.c:92
const char * name
Definition: encode.c:521
int xmloption
Definition: xml.c:98
#define READ_STRING_FIELD(fldname)
Definition: readfuncs.c:123
#define READ_DONE()
Definition: readfuncs.c:175
#define READ_INT_FIELD(fldname)
Definition: readfuncs.c:68

◆ parseNodeString()

Node* parseNodeString ( void  )

Definition at line 2562 of file readfuncs.c.

References _readAgg(), _readAggref(), _readAlias(), _readAlternativeSubPlan(), _readAppend(), _readArrayCoerceExpr(), _readArrayExpr(), _readBitmapAnd(), _readBitmapHeapScan(), _readBitmapIndexScan(), _readBitmapOr(), _readBooleanTest(), _readBoolExpr(), _readCaseExpr(), _readCaseTestExpr(), _readCaseWhen(), _readCoalesceExpr(), _readCoerceToDomain(), _readCoerceToDomainValue(), _readCoerceViaIO(), _readCollateExpr(), _readCommonTableExpr(), _readConst(), _readConvertRowtypeExpr(), _readCteScan(), _readCurrentOfExpr(), _readCustomScan(), _readDeclareCursorStmt(), _readDefElem(), _readDistinctExpr(), _readExtensibleNode(), _readFieldSelect(), _readFieldStore(), _readForeignScan(), _readFromExpr(), _readFuncExpr(), _readFunctionScan(), _readGather(), _readGatherMerge(), _readGroup(), _readGroupingFunc(), _readGroupingSet(), _readHash(), _readHashJoin(), _readIndexOnlyScan(), _readIndexScan(), _readInferenceElem(), _readIntoClause(), _readJoin(), _readJoinExpr(), _readLimit(), _readLockRows(), _readMaterial(), _readMergeAppend(), _readMergeJoin(), _readMinMaxExpr(), _readModifyTable(), _readNamedArgExpr(), _readNamedTuplestoreScan(), _readNestLoop(), _readNestLoopParam(), _readNextValueExpr(), _readNotifyStmt(), _readNullIfExpr(), _readNullTest(), _readOnConflictExpr(), _readOpExpr(), _readParam(), _readPartitionBoundSpec(), _readPartitionedRelPruneInfo(), _readPartitionPruneInfo(), _readPartitionPruneStepCombine(), _readPartitionPruneStepOp(), _readPartitionRangeDatum(), _readPlan(), _readPlanInvalItem(), _readPlannedStmt(), _readPlanRowMark(), _readProjectSet(), _readQuery(), _readRangeTblEntry(), _readRangeTblFunction(), _readRangeTblRef(), _readRangeVar(), _readRecursiveUnion(), _readRelabelType(), _readResult(), _readRowCompareExpr(), _readRowExpr(), _readRowMarkClause(), _readSampleScan(), _readScalarArrayOpExpr(), _readScan(), _readSeqScan(), _readSetOp(), _readSetOperationStmt(), _readSetToDefault(), _readSort(), _readSortGroupClause(), _readSQLValueFunction(), _readSubLink(), _readSubPlan(), _readSubqueryScan(), _readSubscriptingRef(), _readTableFunc(), _readTableFuncScan(), _readTableSampleClause(), _readTargetEntry(), _readTidScan(), _readUnique(), _readValuesScan(), _readVar(), _readWindowAgg(), _readWindowClause(), _readWindowFunc(), _readWithCheckOption(), _readWorkTableScan(), _readXmlExpr(), check_stack_depth(), elog, ERROR, MATCH, pg_strtok(), and READ_TEMP_LOCALS.

Referenced by nodeRead().

2563 {
2564  void *return_value;
2565 
2566  READ_TEMP_LOCALS();
2567 
2568  /* Guard against stack overflow due to overly complex expressions */
2570 
2571  token = pg_strtok(&length);
2572 
2573 #define MATCH(tokname, namelen) \
2574  (length == namelen && memcmp(token, tokname, namelen) == 0)
2575 
2576  if (MATCH("QUERY", 5))
2577  return_value = _readQuery();
2578  else if (MATCH("WITHCHECKOPTION", 15))
2579  return_value = _readWithCheckOption();
2580  else if (MATCH("SORTGROUPCLAUSE", 15))
2581  return_value = _readSortGroupClause();
2582  else if (MATCH("GROUPINGSET", 11))
2583  return_value = _readGroupingSet();
2584  else if (MATCH("WINDOWCLAUSE", 12))
2585  return_value = _readWindowClause();
2586  else if (MATCH("ROWMARKCLAUSE", 13))
2587  return_value = _readRowMarkClause();
2588  else if (MATCH("COMMONTABLEEXPR", 15))
2589  return_value = _readCommonTableExpr();
2590  else if (MATCH("SETOPERATIONSTMT", 16))
2591  return_value = _readSetOperationStmt();
2592  else if (MATCH("ALIAS", 5))
2593  return_value = _readAlias();
2594  else if (MATCH("RANGEVAR", 8))
2595  return_value = _readRangeVar();
2596  else if (MATCH("INTOCLAUSE", 10))
2597  return_value = _readIntoClause();
2598  else if (MATCH("TABLEFUNC", 9))
2599  return_value = _readTableFunc();
2600  else if (MATCH("VAR", 3))
2601  return_value = _readVar();
2602  else if (MATCH("CONST", 5))
2603  return_value = _readConst();
2604  else if (MATCH("PARAM", 5))
2605  return_value = _readParam();
2606  else if (MATCH("AGGREF", 6))
2607  return_value = _readAggref();
2608  else if (MATCH("GROUPINGFUNC", 12))
2609  return_value = _readGroupingFunc();
2610  else if (MATCH("WINDOWFUNC", 10))
2611  return_value = _readWindowFunc();
2612  else if (MATCH("SUBSCRIPTINGREF", 15))
2613  return_value = _readSubscriptingRef();
2614  else if (MATCH("FUNCEXPR", 8))
2615  return_value = _readFuncExpr();
2616  else if (MATCH("NAMEDARGEXPR", 12))
2617  return_value = _readNamedArgExpr();
2618  else if (MATCH("OPEXPR", 6))
2619  return_value = _readOpExpr();
2620  else if (MATCH("DISTINCTEXPR", 12))
2621  return_value = _readDistinctExpr();
2622  else if (MATCH("NULLIFEXPR", 10))
2623  return_value = _readNullIfExpr();
2624  else if (MATCH("SCALARARRAYOPEXPR", 17))
2625  return_value = _readScalarArrayOpExpr();
2626  else if (MATCH("BOOLEXPR", 8))
2627  return_value = _readBoolExpr();
2628  else if (MATCH("SUBLINK", 7))
2629  return_value = _readSubLink();
2630  else if (MATCH("FIELDSELECT", 11))
2631  return_value = _readFieldSelect();
2632  else if (MATCH("FIELDSTORE", 10))
2633  return_value = _readFieldStore();
2634  else if (MATCH("RELABELTYPE", 11))
2635  return_value = _readRelabelType();
2636  else if (MATCH("COERCEVIAIO", 11))
2637  return_value = _readCoerceViaIO();
2638  else if (MATCH("ARRAYCOERCEEXPR", 15))
2639  return_value = _readArrayCoerceExpr();
2640  else if (MATCH("CONVERTROWTYPEEXPR", 18))
2641  return_value = _readConvertRowtypeExpr();
2642  else if (MATCH("COLLATE", 7))
2643  return_value = _readCollateExpr();
2644  else if (MATCH("CASE", 4))
2645  return_value = _readCaseExpr();
2646  else if (MATCH("WHEN", 4))
2647  return_value = _readCaseWhen();
2648  else if (MATCH("CASETESTEXPR", 12))
2649  return_value = _readCaseTestExpr();
2650  else if (MATCH("ARRAY", 5))
2651  return_value = _readArrayExpr();
2652  else if (MATCH("ROW", 3))
2653  return_value = _readRowExpr();
2654  else if (MATCH("ROWCOMPARE", 10))
2655  return_value = _readRowCompareExpr();
2656  else if (MATCH("COALESCE", 8))
2657  return_value = _readCoalesceExpr();
2658  else if (MATCH("MINMAX", 6))
2659  return_value = _readMinMaxExpr();
2660  else if (MATCH("SQLVALUEFUNCTION", 16))
2661  return_value = _readSQLValueFunction();
2662  else if (MATCH("XMLEXPR", 7))
2663  return_value = _readXmlExpr();
2664  else if (MATCH("NULLTEST", 8))
2665  return_value = _readNullTest();
2666  else if (MATCH("BOOLEANTEST", 11))
2667  return_value = _readBooleanTest();
2668  else if (MATCH("COERCETODOMAIN", 14))
2669  return_value = _readCoerceToDomain();
2670  else if (MATCH("COERCETODOMAINVALUE", 19))
2671  return_value = _readCoerceToDomainValue();
2672  else if (MATCH("SETTODEFAULT", 12))
2673  return_value = _readSetToDefault();
2674  else if (MATCH("CURRENTOFEXPR", 13))
2675  return_value = _readCurrentOfExpr();
2676  else if (MATCH("NEXTVALUEEXPR", 13))
2677  return_value = _readNextValueExpr();
2678  else if (MATCH("INFERENCEELEM", 13))
2679  return_value = _readInferenceElem();
2680  else if (MATCH("TARGETENTRY", 11))
2681  return_value = _readTargetEntry();
2682  else if (MATCH("RANGETBLREF", 11))
2683  return_value = _readRangeTblRef();
2684  else if (MATCH("JOINEXPR", 8))
2685  return_value = _readJoinExpr();
2686  else if (MATCH("FROMEXPR", 8))
2687  return_value = _readFromExpr();
2688  else if (MATCH("ONCONFLICTEXPR", 14))
2689  return_value = _readOnConflictExpr();
2690  else if (MATCH("RTE", 3))
2691  return_value = _readRangeTblEntry();
2692  else if (MATCH("RANGETBLFUNCTION", 16))
2693  return_value = _readRangeTblFunction();
2694  else if (MATCH("TABLESAMPLECLAUSE", 17))
2695  return_value = _readTableSampleClause();
2696  else if (MATCH("NOTIFY", 6))
2697  return_value = _readNotifyStmt();
2698  else if (MATCH("DEFELEM", 7))
2699  return_value = _readDefElem();
2700  else if (MATCH("DECLARECURSOR", 13))
2701  return_value = _readDeclareCursorStmt();
2702  else if (MATCH("PLANNEDSTMT", 11))
2703  return_value = _readPlannedStmt();
2704  else if (MATCH("PLAN", 4))
2705  return_value = _readPlan();
2706  else if (MATCH("RESULT", 6))
2707  return_value = _readResult();
2708  else if (MATCH("PROJECTSET", 10))
2709  return_value = _readProjectSet();
2710  else if (MATCH("MODIFYTABLE", 11))
2711  return_value = _readModifyTable();
2712  else if (MATCH("APPEND", 6))
2713  return_value = _readAppend();
2714  else if (MATCH("MERGEAPPEND", 11))
2715  return_value = _readMergeAppend();
2716  else if (MATCH("RECURSIVEUNION", 14))
2717  return_value = _readRecursiveUnion();
2718  else if (MATCH("BITMAPAND", 9))
2719  return_value = _readBitmapAnd();
2720  else if (MATCH("BITMAPOR", 8))
2721  return_value = _readBitmapOr();
2722  else if (MATCH("SCAN", 4))
2723  return_value = _readScan();
2724  else if (MATCH("SEQSCAN", 7))
2725  return_value = _readSeqScan();
2726  else if (MATCH("SAMPLESCAN", 10))
2727  return_value = _readSampleScan();
2728  else if (MATCH("INDEXSCAN", 9))
2729  return_value = _readIndexScan();
2730  else if (MATCH("INDEXONLYSCAN", 13))
2731  return_value = _readIndexOnlyScan();
2732  else if (MATCH("BITMAPINDEXSCAN", 15))
2733  return_value = _readBitmapIndexScan();
2734  else if (MATCH("BITMAPHEAPSCAN", 14))
2735  return_value = _readBitmapHeapScan();
2736  else if (MATCH("TIDSCAN", 7))
2737  return_value = _readTidScan();
2738  else if (MATCH("SUBQUERYSCAN", 12))
2739  return_value = _readSubqueryScan();
2740  else if (MATCH("FUNCTIONSCAN", 12))
2741  return_value = _readFunctionScan();
2742  else if (MATCH("VALUESSCAN", 10))
2743  return_value = _readValuesScan();
2744  else if (MATCH("TABLEFUNCSCAN", 13))
2745  return_value = _readTableFuncScan();
2746  else if (MATCH("CTESCAN", 7))
2747  return_value = _readCteScan();
2748  else if (MATCH("NAMEDTUPLESTORESCAN", 19))
2749  return_value = _readNamedTuplestoreScan();
2750  else if (MATCH("WORKTABLESCAN", 13))
2751  return_value = _readWorkTableScan();
2752  else if (MATCH("FOREIGNSCAN", 11))
2753  return_value = _readForeignScan();
2754  else if (MATCH("CUSTOMSCAN", 10))
2755  return_value = _readCustomScan();
2756  else if (MATCH("JOIN", 4))
2757  return_value = _readJoin();
2758  else if (MATCH("NESTLOOP", 8))
2759  return_value = _readNestLoop();
2760  else if (MATCH("MERGEJOIN", 9))
2761  return_value = _readMergeJoin();
2762  else if (MATCH("HASHJOIN", 8))
2763  return_value = _readHashJoin();
2764  else if (MATCH("MATERIAL", 8))
2765  return_value = _readMaterial();
2766  else if (MATCH("SORT", 4))
2767  return_value = _readSort();
2768  else if (MATCH("GROUP", 5))
2769  return_value = _readGroup();
2770  else if (MATCH("AGG", 3))
2771  return_value = _readAgg();
2772  else if (MATCH("WINDOWAGG", 9))
2773  return_value = _readWindowAgg();
2774  else if (MATCH("UNIQUE", 6))
2775  return_value = _readUnique();
2776  else if (MATCH("GATHER", 6))
2777  return_value = _readGather();
2778  else if (MATCH("GATHERMERGE", 11))
2779  return_value = _readGatherMerge();
2780  else if (MATCH("HASH", 4))
2781  return_value = _readHash();
2782  else if (MATCH("SETOP", 5))
2783  return_value = _readSetOp();
2784  else if (MATCH("LOCKROWS", 8))
2785  return_value = _readLockRows();
2786  else if (MATCH("LIMIT", 5))
2787  return_value = _readLimit();
2788  else if (MATCH("NESTLOOPPARAM", 13))
2789  return_value = _readNestLoopParam();
2790  else if (MATCH("PLANROWMARK", 11))
2791  return_value = _readPlanRowMark();
2792  else if (MATCH("PARTITIONPRUNEINFO", 18))
2793  return_value = _readPartitionPruneInfo();
2794  else if (MATCH("PARTITIONEDRELPRUNEINFO", 23))
2795  return_value = _readPartitionedRelPruneInfo();
2796  else if (MATCH("PARTITIONPRUNESTEPOP", 20))
2797  return_value = _readPartitionPruneStepOp();
2798  else if (MATCH("PARTITIONPRUNESTEPCOMBINE", 25))
2799  return_value = _readPartitionPruneStepCombine();
2800  else if (MATCH("PLANINVALITEM", 13))
2801  return_value = _readPlanInvalItem();
2802  else if (MATCH("SUBPLAN", 7))
2803  return_value = _readSubPlan();
2804  else if (MATCH("ALTERNATIVESUBPLAN", 18))
2805  return_value = _readAlternativeSubPlan();
2806  else if (MATCH("EXTENSIBLENODE", 14))
2807  return_value = _readExtensibleNode();
2808  else if (MATCH("PARTITIONBOUNDSPEC", 18))
2809  return_value = _readPartitionBoundSpec();
2810  else if (MATCH("PARTITIONRANGEDATUM", 19))
2811  return_value = _readPartitionRangeDatum();
2812  else
2813  {
2814  elog(ERROR, "badly formatted node string \"%.32s\"...", token);
2815  return_value = NULL; /* keep compiler quiet */
2816  }
2817 
2818  return (Node *) return_value;
2819 }
static NullTest * _readNullTest(void)
Definition: readfuncs.c:1138
static JoinExpr * _readJoinExpr(void)
Definition: readfuncs.c:1295
static RangeVar * _readRangeVar(void)
Definition: readfuncs.c:471
static RangeTblEntry * _readRangeTblEntry(void)
Definition: readfuncs.c:1353
static DefElem * _readDefElem(void)
Definition: readfuncs.c:1477
static RowExpr * _readRowExpr(void)
Definition: readfuncs.c:1032
static MergeJoin * _readMergeJoin(void)
Definition: readfuncs.c:2067
static MinMaxExpr * _readMinMaxExpr(void)
Definition: readfuncs.c:1083
static RowMarkClause * _readRowMarkClause(void)
Definition: readfuncs.c:399
static FuncExpr * _readFuncExpr(void)
Definition: readfuncs.c:685
static Hash * _readHash(void)
Definition: readfuncs.c:2274
static Result * _readResult(void)
Definition: readfuncs.c:1570
static Query * _readQuery(void)
Definition: readfuncs.c:247
static RowCompareExpr * _readRowCompareExpr(void)
Definition: readfuncs.c:1049
static Param * _readParam(void)
Definition: readfuncs.c:579
static PlanInvalItem * _readPlanInvalItem(void)
Definition: readfuncs.c:2437
static PartitionPruneInfo * _readPartitionPruneInfo(void)
Definition: readfuncs.c:2379
static WindowAgg * _readWindowAgg(void)
Definition: readfuncs.c:2184
static IndexScan * _readIndexScan(void)
Definition: readfuncs.c:1777
static NotifyStmt * _readNotifyStmt(void)
Definition: readfuncs.c:295
static Scan * _readScan(void)
Definition: readfuncs.c:1736
static NamedArgExpr * _readNamedArgExpr(void)
Definition: readfuncs.c:706
static LockRows * _readLockRows(void)
Definition: readfuncs.c:2316
static CurrentOfExpr * _readCurrentOfExpr(void)
Definition: readfuncs.c:1219
static CollateExpr * _readCollateExpr(void)
Definition: readfuncs.c:951
static SubqueryScan * _readSubqueryScan(void)
Definition: readfuncs.c:1865
static BitmapIndexScan * _readBitmapIndexScan(void)
Definition: readfuncs.c:1817
static CaseExpr * _readCaseExpr(void)
Definition: readfuncs.c:966
static FunctionScan * _readFunctionScan(void)
Definition: readfuncs.c:1880
static PartitionBoundSpec * _readPartitionBoundSpec(void)
Definition: readfuncs.c:2522
static Unique * _readUnique(void)
Definition: readfuncs.c:2215
static MergeAppend * _readMergeAppend(void)
Definition: readfuncs.c:1650
Definition: nodes.h:525
static WindowFunc * _readWindowFunc(void)
Definition: readfuncs.c:643
static WindowClause * _readWindowClause(void)
Definition: readfuncs.c:373
static OpExpr * _readOpExpr(void)
Definition: readfuncs.c:722
static IndexOnlyScan * _readIndexOnlyScan(void)
Definition: readfuncs.c:1798
static BitmapAnd * _readBitmapAnd(void)
Definition: readfuncs.c:1691
static FromExpr * _readFromExpr(void)
Definition: readfuncs.c:1315
static PartitionedRelPruneInfo * _readPartitionedRelPruneInfo(void)
Definition: readfuncs.c:2390
static Aggref * _readAggref(void)
Definition: readfuncs.c:597
static NestLoop * _readNestLoop(void)
Definition: readfuncs.c:2052
static ModifyTable * _readModifyTable(void)
Definition: readfuncs.c:1598
static NextValueExpr * _readNextValueExpr(void)
Definition: readfuncs.c:1234
static DistinctExpr * _readDistinctExpr(void)
Definition: readfuncs.c:742
static ArrayCoerceExpr * _readArrayCoerceExpr(void)
Definition: readfuncs.c:916
static TargetEntry * _readTargetEntry(void)
Definition: readfuncs.c:1263
static Agg * _readAgg(void)
Definition: readfuncs.c:2160
static SeqScan * _readSeqScan(void)
Definition: readfuncs.c:1749
static AlternativeSubPlan * _readAlternativeSubPlan(void)
Definition: readfuncs.c:2479
static CteScan * _readCteScan(void)
Definition: readfuncs.c:1926
#define ERROR
Definition: elog.h:43
static GroupingFunc * _readGroupingFunc(void)
Definition: readfuncs.c:626
static CoerceToDomain * _readCoerceToDomain(void)
Definition: readfuncs.c:1169
static SubLink * _readSubLink(void)
Definition: readfuncs.c:826
static HashJoin * _readHashJoin(void)
Definition: readfuncs.c:2092
static PartitionPruneStepCombine * _readPartitionPruneStepCombine(void)
Definition: readfuncs.c:2422
static ValuesScan * _readValuesScan(void)
Definition: readfuncs.c:1896
static ConvertRowtypeExpr * _readConvertRowtypeExpr(void)
Definition: readfuncs.c:935
static OnConflictExpr * _readOnConflictExpr(void)
Definition: readfuncs.c:1329
static NullIfExpr * _readNullIfExpr(void)
Definition: readfuncs.c:762
static Append * _readAppend(void)
Definition: readfuncs.c:1633
static ExtensibleNode * _readExtensibleNode(void)
Definition: readfuncs.c:2492
static PlanRowMark * _readPlanRowMark(void)
Definition: readfuncs.c:2362
static FieldSelect * _readFieldSelect(void)
Definition: readfuncs.c:848
void check_stack_depth(void)
Definition: postgres.c:3262
static CaseWhen * _readCaseWhen(void)
Definition: readfuncs.c:984
static SQLValueFunction * _readSQLValueFunction(void)
Definition: readfuncs.c:1101
#define MATCH(tokname, namelen)
static ForeignScan * _readForeignScan(void)
Definition: readfuncs.c:1972
static RelabelType * _readRelabelType(void)
Definition: readfuncs.c:881
static SetOp * _readSetOp(void)
Definition: readfuncs.c:2293
static SortGroupClause * _readSortGroupClause(void)
Definition: readfuncs.c:341
static Limit * _readLimit(void)
Definition: readfuncs.c:2332
static PartitionRangeDatum * _readPartitionRangeDatum(void)
Definition: readfuncs.c:2542
static GatherMerge * _readGatherMerge(void)
Definition: readfuncs.c:2252
static DeclareCursorStmt * _readDeclareCursorStmt(void)
Definition: readfuncs.c:309
static Gather * _readGather(void)
Definition: readfuncs.c:2233
#define READ_TEMP_LOCALS()
Definition: readfuncs.c:58
static Var * _readVar(void)
Definition: readfuncs.c:533
static SampleScan * _readSampleScan(void)
Definition: readfuncs.c:1762
static SubPlan * _readSubPlan(void)
Definition: readfuncs.c:2451
static TidScan * _readTidScan(void)
Definition: readfuncs.c:1850
static CoerceToDomainValue * _readCoerceToDomainValue(void)
Definition: readfuncs.c:1187
static TableFuncScan * _readTableFuncScan(void)
Definition: readfuncs.c:1911
static IntoClause * _readIntoClause(void)
Definition: readfuncs.c:513
static Const * _readConst(void)
Definition: readfuncs.c:554
static SetOperationStmt * _readSetOperationStmt(void)
Definition: readfuncs.c:438
static PlannedStmt * _readPlannedStmt(void)
Definition: readfuncs.c:1498
static NamedTuplestoreScan * _readNamedTuplestoreScan(void)
Definition: readfuncs.c:1942
static Material * _readMaterial(void)
Definition: readfuncs.c:2110
static CaseTestExpr * _readCaseTestExpr(void)
Definition: readfuncs.c:999
static Alias * _readAlias(void)
Definition: readfuncs.c:460
static BitmapOr * _readBitmapOr(void)
Definition: readfuncs.c:1706
static RangeTblRef * _readRangeTblRef(void)
Definition: readfuncs.c:1282
static RecursiveUnion * _readRecursiveUnion(void)
Definition: readfuncs.c:1671
static FieldStore * _readFieldStore(void)
Definition: readfuncs.c:865
static CoalesceExpr * _readCoalesceExpr(void)
Definition: readfuncs.c:1067
static SetToDefault * _readSetToDefault(void)
Definition: readfuncs.c:1203
static WithCheckOption * _readWithCheckOption(void)
Definition: readfuncs.c:324
static PartitionPruneStepOp * _readPartitionPruneStepOp(void)
Definition: readfuncs.c:2408
static InferenceElem * _readInferenceElem(void)
Definition: readfuncs.c:1248
static SubscriptingRef * _readSubscriptingRef(void)
Definition: readfuncs.c:665
static ScalarArrayOpExpr * _readScalarArrayOpExpr(void)
Definition: readfuncs.c:782
#define elog(elevel,...)
Definition: elog.h:226
static BoolExpr * _readBoolExpr(void)
Definition: readfuncs.c:800
static CustomScan * _readCustomScan(void)
Definition: readfuncs.c:1994
static CommonTableExpr * _readCommonTableExpr(void)
Definition: readfuncs.c:415
static ArrayExpr * _readArrayExpr(void)
Definition: readfuncs.c:1014
const char * pg_strtok(int *length)
Definition: read.c:152
static RangeTblFunction * _readRangeTblFunction(void)
Definition: readfuncs.c:1443
static BooleanTest * _readBooleanTest(void)
Definition: readfuncs.c:1154
static Plan * _readPlan(void)
Definition: readfuncs.c:1557
static XmlExpr * _readXmlExpr(void)
Definition: readfuncs.c:1117
static TableFunc * _readTableFunc(void)
Definition: readfuncs.c:491
static TableSampleClause * _readTableSampleClause(void)
Definition: readfuncs.c:1462
static NestLoopParam * _readNestLoopParam(void)
Definition: readfuncs.c:2348
static ProjectSet * _readProjectSet(void)
Definition: readfuncs.c:1585
static BitmapHeapScan * _readBitmapHeapScan(void)
Definition: readfuncs.c:1835
static Join * _readJoin(void)
Definition: readfuncs.c:2039
static Sort * _readSort(void)
Definition: readfuncs.c:2123
static CoerceViaIO * _readCoerceViaIO(void)
Definition: readfuncs.c:899
static Group * _readGroup(void)
Definition: readfuncs.c:2142
static GroupingSet * _readGroupingSet(void)
Definition: readfuncs.c:358
static WorkTableScan * _readWorkTableScan(void)
Definition: readfuncs.c:1957

◆ readAttrNumberCols()

AttrNumber* readAttrNumberCols ( int  numCols)

Definition at line 2887 of file readfuncs.c.

References i, palloc(), and pg_strtok().

2888 {
2889  int tokenLength,
2890  i;
2891  const char *token;
2892  AttrNumber *attr_vals;
2893 
2894  if (numCols <= 0)
2895  return NULL;
2896 
2897  attr_vals = (