PostgreSQL Source Code  git master
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros
copyfuncs.c File Reference
#include "postgres.h"
#include "miscadmin.h"
#include "nodes/extensible.h"
#include "nodes/plannodes.h"
#include "nodes/relation.h"
#include "utils/datum.h"
#include "utils/rel.h"
Include dependency graph for copyfuncs.c:

Go to the source code of this file.

Macros

#define COPY_SCALAR_FIELD(fldname)   (newnode->fldname = from->fldname)
 
#define COPY_NODE_FIELD(fldname)   (newnode->fldname = copyObjectImpl(from->fldname))
 
#define COPY_BITMAPSET_FIELD(fldname)   (newnode->fldname = bms_copy(from->fldname))
 
#define COPY_STRING_FIELD(fldname)   (newnode->fldname = from->fldname ? pstrdup(from->fldname) : (char *) NULL)
 
#define COPY_POINTER_FIELD(fldname, sz)
 
#define COPY_LOCATION_FIELD(fldname)   (newnode->fldname = from->fldname)
 
#define COPY_NODE_CELL(new, old)
 

Functions

static PlannedStmt_copyPlannedStmt (const PlannedStmt *from)
 
static void CopyPlanFields (const Plan *from, Plan *newnode)
 
static Plan_copyPlan (const Plan *from)
 
static Result_copyResult (const Result *from)
 
static ProjectSet_copyProjectSet (const ProjectSet *from)
 
static ModifyTable_copyModifyTable (const ModifyTable *from)
 
static Append_copyAppend (const Append *from)
 
static MergeAppend_copyMergeAppend (const MergeAppend *from)
 
static RecursiveUnion_copyRecursiveUnion (const RecursiveUnion *from)
 
static BitmapAnd_copyBitmapAnd (const BitmapAnd *from)
 
static BitmapOr_copyBitmapOr (const BitmapOr *from)
 
static Gather_copyGather (const Gather *from)
 
static GatherMerge_copyGatherMerge (const GatherMerge *from)
 
static void CopyScanFields (const Scan *from, Scan *newnode)
 
static Scan_copyScan (const Scan *from)
 
static SeqScan_copySeqScan (const SeqScan *from)
 
static SampleScan_copySampleScan (const SampleScan *from)
 
static IndexScan_copyIndexScan (const IndexScan *from)
 
static IndexOnlyScan_copyIndexOnlyScan (const IndexOnlyScan *from)
 
static BitmapIndexScan_copyBitmapIndexScan (const BitmapIndexScan *from)
 
static BitmapHeapScan_copyBitmapHeapScan (const BitmapHeapScan *from)
 
static TidScan_copyTidScan (const TidScan *from)
 
static SubqueryScan_copySubqueryScan (const SubqueryScan *from)
 
static FunctionScan_copyFunctionScan (const FunctionScan *from)
 
static TableFuncScan_copyTableFuncScan (const TableFuncScan *from)
 
static ValuesScan_copyValuesScan (const ValuesScan *from)
 
static CteScan_copyCteScan (const CteScan *from)
 
static NamedTuplestoreScan_copyNamedTuplestoreScan (const NamedTuplestoreScan *from)
 
static WorkTableScan_copyWorkTableScan (const WorkTableScan *from)
 
static ForeignScan_copyForeignScan (const ForeignScan *from)
 
static CustomScan_copyCustomScan (const CustomScan *from)
 
static void CopyJoinFields (const Join *from, Join *newnode)
 
static Join_copyJoin (const Join *from)
 
static NestLoop_copyNestLoop (const NestLoop *from)
 
static MergeJoin_copyMergeJoin (const MergeJoin *from)
 
static HashJoin_copyHashJoin (const HashJoin *from)
 
static Material_copyMaterial (const Material *from)
 
static Sort_copySort (const Sort *from)
 
static Group_copyGroup (const Group *from)
 
static Agg_copyAgg (const Agg *from)
 
static WindowAgg_copyWindowAgg (const WindowAgg *from)
 
static Unique_copyUnique (const Unique *from)
 
static Hash_copyHash (const Hash *from)
 
static SetOp_copySetOp (const SetOp *from)
 
static LockRows_copyLockRows (const LockRows *from)
 
static Limit_copyLimit (const Limit *from)
 
static NestLoopParam_copyNestLoopParam (const NestLoopParam *from)
 
static PlanRowMark_copyPlanRowMark (const PlanRowMark *from)
 
static PlanInvalItem_copyPlanInvalItem (const PlanInvalItem *from)
 
static Alias_copyAlias (const Alias *from)
 
static RangeVar_copyRangeVar (const RangeVar *from)
 
static TableFunc_copyTableFunc (const TableFunc *from)
 
static IntoClause_copyIntoClause (const IntoClause *from)
 
static Var_copyVar (const Var *from)
 
static Const_copyConst (const Const *from)
 
static Param_copyParam (const Param *from)
 
static Aggref_copyAggref (const Aggref *from)
 
static GroupingFunc_copyGroupingFunc (const GroupingFunc *from)
 
static WindowFunc_copyWindowFunc (const WindowFunc *from)
 
static ArrayRef_copyArrayRef (const ArrayRef *from)
 
static FuncExpr_copyFuncExpr (const FuncExpr *from)
 
static NamedArgExpr_copyNamedArgExpr (const NamedArgExpr *from)
 
static OpExpr_copyOpExpr (const OpExpr *from)
 
static DistinctExpr_copyDistinctExpr (const DistinctExpr *from)
 
static NullIfExpr_copyNullIfExpr (const NullIfExpr *from)
 
static ScalarArrayOpExpr_copyScalarArrayOpExpr (const ScalarArrayOpExpr *from)
 
static BoolExpr_copyBoolExpr (const BoolExpr *from)
 
static SubLink_copySubLink (const SubLink *from)
 
static SubPlan_copySubPlan (const SubPlan *from)
 
static AlternativeSubPlan_copyAlternativeSubPlan (const AlternativeSubPlan *from)
 
static FieldSelect_copyFieldSelect (const FieldSelect *from)
 
static FieldStore_copyFieldStore (const FieldStore *from)
 
static RelabelType_copyRelabelType (const RelabelType *from)
 
static CoerceViaIO_copyCoerceViaIO (const CoerceViaIO *from)
 
static ArrayCoerceExpr_copyArrayCoerceExpr (const ArrayCoerceExpr *from)
 
static ConvertRowtypeExpr_copyConvertRowtypeExpr (const ConvertRowtypeExpr *from)
 
static CollateExpr_copyCollateExpr (const CollateExpr *from)
 
static CaseExpr_copyCaseExpr (const CaseExpr *from)
 
static CaseWhen_copyCaseWhen (const CaseWhen *from)
 
static CaseTestExpr_copyCaseTestExpr (const CaseTestExpr *from)
 
static ArrayExpr_copyArrayExpr (const ArrayExpr *from)
 
static RowExpr_copyRowExpr (const RowExpr *from)
 
static RowCompareExpr_copyRowCompareExpr (const RowCompareExpr *from)
 
static CoalesceExpr_copyCoalesceExpr (const CoalesceExpr *from)
 
static MinMaxExpr_copyMinMaxExpr (const MinMaxExpr *from)
 
static SQLValueFunction_copySQLValueFunction (const SQLValueFunction *from)
 
static XmlExpr_copyXmlExpr (const XmlExpr *from)
 
static NullTest_copyNullTest (const NullTest *from)
 
static BooleanTest_copyBooleanTest (const BooleanTest *from)
 
static CoerceToDomain_copyCoerceToDomain (const CoerceToDomain *from)
 
static CoerceToDomainValue_copyCoerceToDomainValue (const CoerceToDomainValue *from)
 
static SetToDefault_copySetToDefault (const SetToDefault *from)
 
static CurrentOfExpr_copyCurrentOfExpr (const CurrentOfExpr *from)
 
static NextValueExpr_copyNextValueExpr (const NextValueExpr *from)
 
static InferenceElem_copyInferenceElem (const InferenceElem *from)
 
static TargetEntry_copyTargetEntry (const TargetEntry *from)
 
static RangeTblRef_copyRangeTblRef (const RangeTblRef *from)
 
static JoinExpr_copyJoinExpr (const JoinExpr *from)
 
static FromExpr_copyFromExpr (const FromExpr *from)
 
static OnConflictExpr_copyOnConflictExpr (const OnConflictExpr *from)
 
static PathKey_copyPathKey (const PathKey *from)
 
static RestrictInfo_copyRestrictInfo (const RestrictInfo *from)
 
static PlaceHolderVar_copyPlaceHolderVar (const PlaceHolderVar *from)
 
static SpecialJoinInfo_copySpecialJoinInfo (const SpecialJoinInfo *from)
 
static AppendRelInfo_copyAppendRelInfo (const AppendRelInfo *from)
 
static PartitionedChildRelInfo_copyPartitionedChildRelInfo (const PartitionedChildRelInfo *from)
 
static PlaceHolderInfo_copyPlaceHolderInfo (const PlaceHolderInfo *from)
 
static RangeTblEntry_copyRangeTblEntry (const RangeTblEntry *from)
 
static RangeTblFunction_copyRangeTblFunction (const RangeTblFunction *from)
 
static TableSampleClause_copyTableSampleClause (const TableSampleClause *from)
 
static WithCheckOption_copyWithCheckOption (const WithCheckOption *from)
 
static SortGroupClause_copySortGroupClause (const SortGroupClause *from)
 
static GroupingSet_copyGroupingSet (const GroupingSet *from)
 
static WindowClause_copyWindowClause (const WindowClause *from)
 
static RowMarkClause_copyRowMarkClause (const RowMarkClause *from)
 
static WithClause_copyWithClause (const WithClause *from)
 
static InferClause_copyInferClause (const InferClause *from)
 
static OnConflictClause_copyOnConflictClause (const OnConflictClause *from)
 
static CommonTableExpr_copyCommonTableExpr (const CommonTableExpr *from)
 
static A_Expr_copyAExpr (const A_Expr *from)
 
static ColumnRef_copyColumnRef (const ColumnRef *from)
 
static ParamRef_copyParamRef (const ParamRef *from)
 
static A_Const_copyAConst (const A_Const *from)
 
static FuncCall_copyFuncCall (const FuncCall *from)
 
static A_Star_copyAStar (const A_Star *from)
 
static A_Indices_copyAIndices (const A_Indices *from)
 
static A_Indirection_copyA_Indirection (const A_Indirection *from)
 
static A_ArrayExpr_copyA_ArrayExpr (const A_ArrayExpr *from)
 
static ResTarget_copyResTarget (const ResTarget *from)
 
static MultiAssignRef_copyMultiAssignRef (const MultiAssignRef *from)
 
static TypeName_copyTypeName (const TypeName *from)
 
static SortBy_copySortBy (const SortBy *from)
 
static WindowDef_copyWindowDef (const WindowDef *from)
 
static RangeSubselect_copyRangeSubselect (const RangeSubselect *from)
 
static RangeFunction_copyRangeFunction (const RangeFunction *from)
 
static RangeTableSample_copyRangeTableSample (const RangeTableSample *from)
 
static RangeTableFunc_copyRangeTableFunc (const RangeTableFunc *from)
 
static RangeTableFuncCol_copyRangeTableFuncCol (const RangeTableFuncCol *from)
 
static TypeCast_copyTypeCast (const TypeCast *from)
 
static CollateClause_copyCollateClause (const CollateClause *from)
 
static IndexElem_copyIndexElem (const IndexElem *from)
 
static ColumnDef_copyColumnDef (const ColumnDef *from)
 
static Constraint_copyConstraint (const Constraint *from)
 
static DefElem_copyDefElem (const DefElem *from)
 
static LockingClause_copyLockingClause (const LockingClause *from)
 
static XmlSerialize_copyXmlSerialize (const XmlSerialize *from)
 
static RoleSpec_copyRoleSpec (const RoleSpec *from)
 
static TriggerTransition_copyTriggerTransition (const TriggerTransition *from)
 
static Query_copyQuery (const Query *from)
 
static RawStmt_copyRawStmt (const RawStmt *from)
 
static InsertStmt_copyInsertStmt (const InsertStmt *from)
 
static DeleteStmt_copyDeleteStmt (const DeleteStmt *from)
 
static UpdateStmt_copyUpdateStmt (const UpdateStmt *from)
 
static SelectStmt_copySelectStmt (const SelectStmt *from)
 
static SetOperationStmt_copySetOperationStmt (const SetOperationStmt *from)
 
static AlterTableStmt_copyAlterTableStmt (const AlterTableStmt *from)
 
static AlterTableCmd_copyAlterTableCmd (const AlterTableCmd *from)
 
static AlterCollationStmt_copyAlterCollationStmt (const AlterCollationStmt *from)
 
static AlterDomainStmt_copyAlterDomainStmt (const AlterDomainStmt *from)
 
static GrantStmt_copyGrantStmt (const GrantStmt *from)
 
static ObjectWithArgs_copyObjectWithArgs (const ObjectWithArgs *from)
 
static AccessPriv_copyAccessPriv (const AccessPriv *from)
 
static GrantRoleStmt_copyGrantRoleStmt (const GrantRoleStmt *from)
 
static AlterDefaultPrivilegesStmt_copyAlterDefaultPrivilegesStmt (const AlterDefaultPrivilegesStmt *from)
 
static DeclareCursorStmt_copyDeclareCursorStmt (const DeclareCursorStmt *from)
 
static ClosePortalStmt_copyClosePortalStmt (const ClosePortalStmt *from)
 
static ClusterStmt_copyClusterStmt (const ClusterStmt *from)
 
static CopyStmt_copyCopyStmt (const CopyStmt *from)
 
static void CopyCreateStmtFields (const CreateStmt *from, CreateStmt *newnode)
 
static CreateStmt_copyCreateStmt (const CreateStmt *from)
 
static TableLikeClause_copyTableLikeClause (const TableLikeClause *from)
 
static DefineStmt_copyDefineStmt (const DefineStmt *from)
 
static DropStmt_copyDropStmt (const DropStmt *from)
 
static TruncateStmt_copyTruncateStmt (const TruncateStmt *from)
 
static CommentStmt_copyCommentStmt (const CommentStmt *from)
 
static SecLabelStmt_copySecLabelStmt (const SecLabelStmt *from)
 
static FetchStmt_copyFetchStmt (const FetchStmt *from)
 
static IndexStmt_copyIndexStmt (const IndexStmt *from)
 
static CreateStatsStmt_copyCreateStatsStmt (const CreateStatsStmt *from)
 
static CreateFunctionStmt_copyCreateFunctionStmt (const CreateFunctionStmt *from)
 
static FunctionParameter_copyFunctionParameter (const FunctionParameter *from)
 
static AlterFunctionStmt_copyAlterFunctionStmt (const AlterFunctionStmt *from)
 
static DoStmt_copyDoStmt (const DoStmt *from)
 
static RenameStmt_copyRenameStmt (const RenameStmt *from)
 
static AlterObjectDependsStmt_copyAlterObjectDependsStmt (const AlterObjectDependsStmt *from)
 
static AlterObjectSchemaStmt_copyAlterObjectSchemaStmt (const AlterObjectSchemaStmt *from)
 
static AlterOwnerStmt_copyAlterOwnerStmt (const AlterOwnerStmt *from)
 
static AlterOperatorStmt_copyAlterOperatorStmt (const AlterOperatorStmt *from)
 
static RuleStmt_copyRuleStmt (const RuleStmt *from)
 
static NotifyStmt_copyNotifyStmt (const NotifyStmt *from)
 
static ListenStmt_copyListenStmt (const ListenStmt *from)
 
static UnlistenStmt_copyUnlistenStmt (const UnlistenStmt *from)
 
static TransactionStmt_copyTransactionStmt (const TransactionStmt *from)
 
static CompositeTypeStmt_copyCompositeTypeStmt (const CompositeTypeStmt *from)
 
static CreateEnumStmt_copyCreateEnumStmt (const CreateEnumStmt *from)
 
static CreateRangeStmt_copyCreateRangeStmt (const CreateRangeStmt *from)
 
static AlterEnumStmt_copyAlterEnumStmt (const AlterEnumStmt *from)
 
static ViewStmt_copyViewStmt (const ViewStmt *from)
 
static LoadStmt_copyLoadStmt (const LoadStmt *from)
 
static CreateDomainStmt_copyCreateDomainStmt (const CreateDomainStmt *from)
 
static CreateOpClassStmt_copyCreateOpClassStmt (const CreateOpClassStmt *from)
 
static CreateOpClassItem_copyCreateOpClassItem (const CreateOpClassItem *from)
 
static CreateOpFamilyStmt_copyCreateOpFamilyStmt (const CreateOpFamilyStmt *from)
 
static AlterOpFamilyStmt_copyAlterOpFamilyStmt (const AlterOpFamilyStmt *from)
 
static CreatedbStmt_copyCreatedbStmt (const CreatedbStmt *from)
 
static AlterDatabaseStmt_copyAlterDatabaseStmt (const AlterDatabaseStmt *from)
 
static AlterDatabaseSetStmt_copyAlterDatabaseSetStmt (const AlterDatabaseSetStmt *from)
 
static DropdbStmt_copyDropdbStmt (const DropdbStmt *from)
 
static VacuumStmt_copyVacuumStmt (const VacuumStmt *from)
 
static ExplainStmt_copyExplainStmt (const ExplainStmt *from)
 
static CreateTableAsStmt_copyCreateTableAsStmt (const CreateTableAsStmt *from)
 
static RefreshMatViewStmt_copyRefreshMatViewStmt (const RefreshMatViewStmt *from)
 
static ReplicaIdentityStmt_copyReplicaIdentityStmt (const ReplicaIdentityStmt *from)
 
static AlterSystemStmt_copyAlterSystemStmt (const AlterSystemStmt *from)
 
static CreateSeqStmt_copyCreateSeqStmt (const CreateSeqStmt *from)
 
static AlterSeqStmt_copyAlterSeqStmt (const AlterSeqStmt *from)
 
static VariableSetStmt_copyVariableSetStmt (const VariableSetStmt *from)
 
static VariableShowStmt_copyVariableShowStmt (const VariableShowStmt *from)
 
static DiscardStmt_copyDiscardStmt (const DiscardStmt *from)
 
static CreateTableSpaceStmt_copyCreateTableSpaceStmt (const CreateTableSpaceStmt *from)
 
static DropTableSpaceStmt_copyDropTableSpaceStmt (const DropTableSpaceStmt *from)
 
static AlterTableSpaceOptionsStmt_copyAlterTableSpaceOptionsStmt (const AlterTableSpaceOptionsStmt *from)
 
static AlterTableMoveAllStmt_copyAlterTableMoveAllStmt (const AlterTableMoveAllStmt *from)
 
static CreateExtensionStmt_copyCreateExtensionStmt (const CreateExtensionStmt *from)
 
static AlterExtensionStmt_copyAlterExtensionStmt (const AlterExtensionStmt *from)
 
static AlterExtensionContentsStmt_copyAlterExtensionContentsStmt (const AlterExtensionContentsStmt *from)
 
static CreateFdwStmt_copyCreateFdwStmt (const CreateFdwStmt *from)
 
static AlterFdwStmt_copyAlterFdwStmt (const AlterFdwStmt *from)
 
static CreateForeignServerStmt_copyCreateForeignServerStmt (const CreateForeignServerStmt *from)
 
static AlterForeignServerStmt_copyAlterForeignServerStmt (const AlterForeignServerStmt *from)
 
static CreateUserMappingStmt_copyCreateUserMappingStmt (const CreateUserMappingStmt *from)
 
static AlterUserMappingStmt_copyAlterUserMappingStmt (const AlterUserMappingStmt *from)
 
static DropUserMappingStmt_copyDropUserMappingStmt (const DropUserMappingStmt *from)
 
static CreateForeignTableStmt_copyCreateForeignTableStmt (const CreateForeignTableStmt *from)
 
static ImportForeignSchemaStmt_copyImportForeignSchemaStmt (const ImportForeignSchemaStmt *from)
 
static CreateTransformStmt_copyCreateTransformStmt (const CreateTransformStmt *from)
 
static CreateAmStmt_copyCreateAmStmt (const CreateAmStmt *from)
 
static CreateTrigStmt_copyCreateTrigStmt (const CreateTrigStmt *from)
 
static CreateEventTrigStmt_copyCreateEventTrigStmt (const CreateEventTrigStmt *from)
 
static AlterEventTrigStmt_copyAlterEventTrigStmt (const AlterEventTrigStmt *from)
 
static CreatePLangStmt_copyCreatePLangStmt (const CreatePLangStmt *from)
 
static CreateRoleStmt_copyCreateRoleStmt (const CreateRoleStmt *from)
 
static AlterRoleStmt_copyAlterRoleStmt (const AlterRoleStmt *from)
 
static AlterRoleSetStmt_copyAlterRoleSetStmt (const AlterRoleSetStmt *from)
 
static DropRoleStmt_copyDropRoleStmt (const DropRoleStmt *from)
 
static LockStmt_copyLockStmt (const LockStmt *from)
 
static ConstraintsSetStmt_copyConstraintsSetStmt (const ConstraintsSetStmt *from)
 
static ReindexStmt_copyReindexStmt (const ReindexStmt *from)
 
static CreateSchemaStmt_copyCreateSchemaStmt (const CreateSchemaStmt *from)
 
static CreateConversionStmt_copyCreateConversionStmt (const CreateConversionStmt *from)
 
static CreateCastStmt_copyCreateCastStmt (const CreateCastStmt *from)
 
static PrepareStmt_copyPrepareStmt (const PrepareStmt *from)
 
static ExecuteStmt_copyExecuteStmt (const ExecuteStmt *from)
 
static DeallocateStmt_copyDeallocateStmt (const DeallocateStmt *from)
 
static DropOwnedStmt_copyDropOwnedStmt (const DropOwnedStmt *from)
 
static ReassignOwnedStmt_copyReassignOwnedStmt (const ReassignOwnedStmt *from)
 
static AlterTSDictionaryStmt_copyAlterTSDictionaryStmt (const AlterTSDictionaryStmt *from)
 
static AlterTSConfigurationStmt_copyAlterTSConfigurationStmt (const AlterTSConfigurationStmt *from)
 
static CreatePolicyStmt_copyCreatePolicyStmt (const CreatePolicyStmt *from)
 
static AlterPolicyStmt_copyAlterPolicyStmt (const AlterPolicyStmt *from)
 
static PartitionElem_copyPartitionElem (const PartitionElem *from)
 
static PartitionSpec_copyPartitionSpec (const PartitionSpec *from)
 
static PartitionBoundSpec_copyPartitionBoundSpec (const PartitionBoundSpec *from)
 
static PartitionRangeDatum_copyPartitionRangeDatum (const PartitionRangeDatum *from)
 
static PartitionCmd_copyPartitionCmd (const PartitionCmd *from)
 
static CreatePublicationStmt_copyCreatePublicationStmt (const CreatePublicationStmt *from)
 
static AlterPublicationStmt_copyAlterPublicationStmt (const AlterPublicationStmt *from)
 
static CreateSubscriptionStmt_copyCreateSubscriptionStmt (const CreateSubscriptionStmt *from)
 
static AlterSubscriptionStmt_copyAlterSubscriptionStmt (const AlterSubscriptionStmt *from)
 
static DropSubscriptionStmt_copyDropSubscriptionStmt (const DropSubscriptionStmt *from)
 
static List_copyList (const List *from)
 
static ExtensibleNode_copyExtensibleNode (const ExtensibleNode *from)
 
static Value_copyValue (const Value *from)
 
static ForeignKeyCacheInfo_copyForeignKeyCacheInfo (const ForeignKeyCacheInfo *from)
 
void * copyObjectImpl (const void *from)
 

Macro Definition Documentation

#define COPY_NODE_CELL (   new,
  old 
)
Value:
(new) = (ListCell *) palloc(sizeof(ListCell)); \
#define lfirst(lc)
Definition: pg_list.h:106
void * palloc(Size size)
Definition: mcxt.c:849
void * copyObjectImpl(const void *from)
Definition: copyfuncs.c:4666

Definition at line 4555 of file copyfuncs.c.

Referenced by _copyList().

#define COPY_NODE_FIELD (   fldname)    (newnode->fldname = copyObjectImpl(from->fldname))

Definition at line 45 of file copyfuncs.c.

Referenced by _copyA_ArrayExpr(), _copyA_Indirection(), _copyAccessPriv(), _copyAExpr(), _copyAgg(), _copyAggref(), _copyAIndices(), _copyAlias(), _copyAlterCollationStmt(), _copyAlterDatabaseSetStmt(), _copyAlterDatabaseStmt(), _copyAlterDefaultPrivilegesStmt(), _copyAlterDomainStmt(), _copyAlterEnumStmt(), _copyAlterExtensionContentsStmt(), _copyAlterExtensionStmt(), _copyAlterFdwStmt(), _copyAlterForeignServerStmt(), _copyAlterFunctionStmt(), _copyAlternativeSubPlan(), _copyAlterObjectDependsStmt(), _copyAlterObjectSchemaStmt(), _copyAlterOperatorStmt(), _copyAlterOpFamilyStmt(), _copyAlterOwnerStmt(), _copyAlterPolicyStmt(), _copyAlterPublicationStmt(), _copyAlterRoleSetStmt(), _copyAlterRoleStmt(), _copyAlterSeqStmt(), _copyAlterSubscriptionStmt(), _copyAlterSystemStmt(), _copyAlterTableCmd(), _copyAlterTableMoveAllStmt(), _copyAlterTableSpaceOptionsStmt(), _copyAlterTableStmt(), _copyAlterTSConfigurationStmt(), _copyAlterTSDictionaryStmt(), _copyAlterUserMappingStmt(), _copyAppend(), _copyAppendRelInfo(), _copyArrayCoerceExpr(), _copyArrayExpr(), _copyArrayRef(), _copyBitmapAnd(), _copyBitmapHeapScan(), _copyBitmapIndexScan(), _copyBitmapOr(), _copyBooleanTest(), _copyBoolExpr(), _copyCaseExpr(), _copyCaseWhen(), _copyClusterStmt(), _copyCoalesceExpr(), _copyCoerceToDomain(), _copyCoerceViaIO(), _copyCollateClause(), _copyCollateExpr(), _copyColumnDef(), _copyColumnRef(), _copyCommentStmt(), _copyCommonTableExpr(), _copyCompositeTypeStmt(), _copyConstraint(), _copyConstraintsSetStmt(), _copyConvertRowtypeExpr(), _copyCopyStmt(), _copyCreateAmStmt(), _copyCreateCastStmt(), _copyCreateConversionStmt(), _copyCreatedbStmt(), _copyCreateDomainStmt(), _copyCreateEnumStmt(), _copyCreateEventTrigStmt(), _copyCreateExtensionStmt(), _copyCreateFdwStmt(), _copyCreateForeignServerStmt(), _copyCreateForeignTableStmt(), _copyCreateFunctionStmt(), _copyCreateOpClassItem(), _copyCreateOpClassStmt(), _copyCreateOpFamilyStmt(), _copyCreatePLangStmt(), _copyCreatePolicyStmt(), _copyCreatePublicationStmt(), _copyCreateRangeStmt(), _copyCreateRoleStmt(), _copyCreateSchemaStmt(), _copyCreateSeqStmt(), _copyCreateStatsStmt(), _copyCreateSubscriptionStmt(), _copyCreateTableAsStmt(), _copyCreateTableSpaceStmt(), _copyCreateTransformStmt(), _copyCreateTrigStmt(), _copyCreateUserMappingStmt(), _copyCustomScan(), _copyDeclareCursorStmt(), _copyDefElem(), _copyDefineStmt(), _copyDeleteStmt(), _copyDistinctExpr(), _copyDoStmt(), _copyDropOwnedStmt(), _copyDropRoleStmt(), _copyDropStmt(), _copyDropUserMappingStmt(), _copyExecuteStmt(), _copyExplainStmt(), _copyFieldSelect(), _copyFieldStore(), _copyForeignScan(), _copyFromExpr(), _copyFuncCall(), _copyFuncExpr(), _copyFunctionParameter(), _copyFunctionScan(), _copyGrantRoleStmt(), _copyGrantStmt(), _copyGroupingFunc(), _copyGroupingSet(), _copyHashJoin(), _copyImportForeignSchemaStmt(), _copyIndexElem(), _copyIndexOnlyScan(), _copyIndexScan(), _copyIndexStmt(), _copyInferClause(), _copyInferenceElem(), _copyInsertStmt(), _copyIntoClause(), _copyJoinExpr(), _copyLimit(), _copyLockingClause(), _copyLockRows(), _copyLockStmt(), _copyMergeAppend(), _copyMergeJoin(), _copyMinMaxExpr(), _copyModifyTable(), _copyMultiAssignRef(), _copyNamedArgExpr(), _copyNestLoop(), _copyNestLoopParam(), _copyNullIfExpr(), _copyNullTest(), _copyObjectWithArgs(), _copyOnConflictClause(), _copyOnConflictExpr(), _copyOpExpr(), _copyPartitionBoundSpec(), _copyPartitionCmd(), _copyPartitionedChildRelInfo(), _copyPartitionElem(), _copyPartitionRangeDatum(), _copyPartitionSpec(), _copyPlaceHolderInfo(), _copyPlaceHolderVar(), _copyPlannedStmt(), _copyPrepareStmt(), _copyQuery(), _copyRangeFunction(), _copyRangeSubselect(), _copyRangeTableFunc(), _copyRangeTableFuncCol(), _copyRangeTableSample(), _copyRangeTblEntry(), _copyRangeTblFunction(), _copyRangeVar(), _copyRawStmt(), _copyReassignOwnedStmt(), _copyRefreshMatViewStmt(), _copyReindexStmt(), _copyRelabelType(), _copyRenameStmt(), _copyResTarget(), _copyRestrictInfo(), _copyResult(), _copyRowCompareExpr(), _copyRowExpr(), _copyRuleStmt(), _copySampleScan(), _copyScalarArrayOpExpr(), _copySecLabelStmt(), _copySelectStmt(), _copySetOperationStmt(), _copySortBy(), _copySpecialJoinInfo(), _copySubLink(), _copySubPlan(), _copySubqueryScan(), _copyTableFunc(), _copyTableFuncScan(), _copyTableLikeClause(), _copyTableSampleClause(), _copyTargetEntry(), _copyTidScan(), _copyTransactionStmt(), _copyTruncateStmt(), _copyTypeCast(), _copyTypeName(), _copyUpdateStmt(), _copyVacuumStmt(), _copyValuesScan(), _copyVariableSetStmt(), _copyViewStmt(), _copyWindowAgg(), _copyWindowClause(), _copyWindowDef(), _copyWindowFunc(), _copyWithCheckOption(), _copyWithClause(), _copyXmlExpr(), _copyXmlSerialize(), CopyCreateStmtFields(), CopyJoinFields(), and CopyPlanFields().

#define COPY_POINTER_FIELD (   fldname,
  sz 
)
Value:
do { \
Size _size = (sz); \
newnode->fldname = palloc(_size); \
memcpy(newnode->fldname, from->fldname, _size); \
} while (0)
size_t Size
Definition: c.h:356
void * palloc(Size size)
Definition: mcxt.c:849

Definition at line 57 of file copyfuncs.c.

Referenced by _copyAgg(), _copyGatherMerge(), _copyGroup(), _copyMergeAppend(), _copyMergeJoin(), _copyRecursiveUnion(), _copySetOp(), _copySort(), _copyUnique(), and _copyWindowAgg().

#define COPY_SCALAR_FIELD (   fldname)    (newnode->fldname = from->fldname)

Definition at line 41 of file copyfuncs.c.

Referenced by _copyAConst(), _copyAExpr(), _copyAgg(), _copyAggref(), _copyAIndices(), _copyAlterDomainStmt(), _copyAlterEnumStmt(), _copyAlterEventTrigStmt(), _copyAlterExtensionContentsStmt(), _copyAlterForeignServerStmt(), _copyAlterObjectDependsStmt(), _copyAlterObjectSchemaStmt(), _copyAlterOpFamilyStmt(), _copyAlterOwnerStmt(), _copyAlterPublicationStmt(), _copyAlterRoleStmt(), _copyAlterSeqStmt(), _copyAlterSubscriptionStmt(), _copyAlterTableCmd(), _copyAlterTableMoveAllStmt(), _copyAlterTableSpaceOptionsStmt(), _copyAlterTableStmt(), _copyAlterTSConfigurationStmt(), _copyAppendRelInfo(), _copyArrayCoerceExpr(), _copyArrayExpr(), _copyArrayRef(), _copyBitmapIndexScan(), _copyBitmapOr(), _copyBooleanTest(), _copyBoolExpr(), _copyCaseExpr(), _copyCaseTestExpr(), _copyClusterStmt(), _copyCoalesceExpr(), _copyCoerceToDomain(), _copyCoerceToDomainValue(), _copyCoerceViaIO(), _copyCollateExpr(), _copyColumnDef(), _copyCommentStmt(), _copyCommonTableExpr(), _copyConst(), _copyConstraint(), _copyConstraintsSetStmt(), _copyConvertRowtypeExpr(), _copyCopyStmt(), _copyCreateAmStmt(), _copyCreateCastStmt(), _copyCreateConversionStmt(), _copyCreateExtensionStmt(), _copyCreateForeignServerStmt(), _copyCreateFunctionStmt(), _copyCreateOpClassItem(), _copyCreateOpClassStmt(), _copyCreatePLangStmt(), _copyCreatePolicyStmt(), _copyCreatePublicationStmt(), _copyCreateRoleStmt(), _copyCreateSchemaStmt(), _copyCreateSeqStmt(), _copyCreateStatsStmt(), _copyCreateTableAsStmt(), _copyCreateTransformStmt(), _copyCreateTrigStmt(), _copyCreateUserMappingStmt(), _copyCteScan(), _copyCurrentOfExpr(), _copyCustomScan(), _copyDeclareCursorStmt(), _copyDefElem(), _copyDefineStmt(), _copyDiscardStmt(), _copyDistinctExpr(), _copyDropdbStmt(), _copyDropOwnedStmt(), _copyDropRoleStmt(), _copyDropStmt(), _copyDropSubscriptionStmt(), _copyDropTableSpaceStmt(), _copyDropUserMappingStmt(), _copyFetchStmt(), _copyFieldSelect(), _copyFieldStore(), _copyForeignKeyCacheInfo(), _copyForeignScan(), _copyFuncCall(), _copyFuncExpr(), _copyFunctionParameter(), _copyFunctionScan(), _copyGather(), _copyGatherMerge(), _copyGrantRoleStmt(), _copyGrantStmt(), _copyGroup(), _copyGroupingFunc(), _copyGroupingSet(), _copyHash(), _copyImportForeignSchemaStmt(), _copyIndexElem(), _copyIndexOnlyScan(), _copyIndexScan(), _copyIndexStmt(), _copyInferenceElem(), _copyInsertStmt(), _copyIntoClause(), _copyJoinExpr(), _copyLockingClause(), _copyLockRows(), _copyLockStmt(), _copyMergeAppend(), _copyMergeJoin(), _copyMinMaxExpr(), _copyModifyTable(), _copyMultiAssignRef(), _copyNamedArgExpr(), _copyNestLoopParam(), _copyNextValueExpr(), _copyNullIfExpr(), _copyNullTest(), _copyObjectWithArgs(), _copyOnConflictClause(), _copyOnConflictExpr(), _copyOpExpr(), _copyParam(), _copyParamRef(), _copyPartitionBoundSpec(), _copyPartitionedChildRelInfo(), _copyPartitionRangeDatum(), _copyPathKey(), _copyPlaceHolderInfo(), _copyPlaceHolderVar(), _copyPlanInvalItem(), _copyPlannedStmt(), _copyPlanRowMark(), _copyQuery(), _copyRangeFunction(), _copyRangeSubselect(), _copyRangeTableFunc(), _copyRangeTableFuncCol(), _copyRangeTblEntry(), _copyRangeTblFunction(), _copyRangeTblRef(), _copyRangeVar(), _copyRecursiveUnion(), _copyRefreshMatViewStmt(), _copyReindexStmt(), _copyRelabelType(), _copyRenameStmt(), _copyReplicaIdentityStmt(), _copyRestrictInfo(), _copyRoleSpec(), _copyRowCompareExpr(), _copyRowExpr(), _copyRowMarkClause(), _copyRuleStmt(), _copyScalarArrayOpExpr(), _copySecLabelStmt(), _copySelectStmt(), _copySetOp(), _copySetOperationStmt(), _copySetToDefault(), _copySort(), _copySortBy(), _copySortGroupClause(), _copySpecialJoinInfo(), _copySQLValueFunction(), _copySubLink(), _copySubPlan(), _copyTableFunc(), _copyTableLikeClause(), _copyTableSampleClause(), _copyTargetEntry(), _copyTransactionStmt(), _copyTriggerTransition(), _copyTruncateStmt(), _copyTypeName(), _copyUnique(), _copyVacuumStmt(), _copyValue(), _copyVar(), _copyVariableSetStmt(), _copyViewStmt(), _copyWindowAgg(), _copyWindowClause(), _copyWindowDef(), _copyWindowFunc(), _copyWithCheckOption(), _copyWithClause(), _copyWorkTableScan(), _copyXmlExpr(), _copyXmlSerialize(), CopyCreateStmtFields(), CopyJoinFields(), CopyPlanFields(), and CopyScanFields().

#define COPY_STRING_FIELD (   fldname)    (newnode->fldname = from->fldname ? pstrdup(from->fldname) : (char *) NULL)

Definition at line 53 of file copyfuncs.c.

Referenced by _copyAccessPriv(), _copyAConst(), _copyAlias(), _copyAlterDatabaseSetStmt(), _copyAlterDatabaseStmt(), _copyAlterDomainStmt(), _copyAlterEnumStmt(), _copyAlterEventTrigStmt(), _copyAlterExtensionContentsStmt(), _copyAlterExtensionStmt(), _copyAlterFdwStmt(), _copyAlterForeignServerStmt(), _copyAlterObjectSchemaStmt(), _copyAlterOpFamilyStmt(), _copyAlterPolicyStmt(), _copyAlterPublicationStmt(), _copyAlterRoleSetStmt(), _copyAlterSubscriptionStmt(), _copyAlterTableCmd(), _copyAlterTableMoveAllStmt(), _copyAlterTableSpaceOptionsStmt(), _copyAlterUserMappingStmt(), _copyClosePortalStmt(), _copyClusterStmt(), _copyColumnDef(), _copyCommentStmt(), _copyCommonTableExpr(), _copyConstraint(), _copyCopyStmt(), _copyCreateAmStmt(), _copyCreateConversionStmt(), _copyCreatedbStmt(), _copyCreateEventTrigStmt(), _copyCreateExtensionStmt(), _copyCreateFdwStmt(), _copyCreateForeignServerStmt(), _copyCreateForeignTableStmt(), _copyCreateOpClassStmt(), _copyCreateOpFamilyStmt(), _copyCreatePLangStmt(), _copyCreatePolicyStmt(), _copyCreatePublicationStmt(), _copyCreateRoleStmt(), _copyCreateSchemaStmt(), _copyCreateSubscriptionStmt(), _copyCreateTableSpaceStmt(), _copyCreateTransformStmt(), _copyCreateTrigStmt(), _copyCreateUserMappingStmt(), _copyCurrentOfExpr(), _copyDeallocateStmt(), _copyDeclareCursorStmt(), _copyDefElem(), _copyDropdbStmt(), _copyDropSubscriptionStmt(), _copyDropTableSpaceStmt(), _copyDropUserMappingStmt(), _copyExecuteStmt(), _copyExtensibleNode(), _copyFetchStmt(), _copyFunctionParameter(), _copyImportForeignSchemaStmt(), _copyIndexElem(), _copyIndexStmt(), _copyInferClause(), _copyIntoClause(), _copyListenStmt(), _copyLoadStmt(), _copyNamedArgExpr(), _copyNamedTuplestoreScan(), _copyNotifyStmt(), _copyPartitionElem(), _copyPartitionSpec(), _copyPrepareStmt(), _copyRangeTableFuncCol(), _copyRangeTblEntry(), _copyRangeVar(), _copyReindexStmt(), _copyRenameStmt(), _copyReplicaIdentityStmt(), _copyResTarget(), _copyRoleSpec(), _copyRuleStmt(), _copySecLabelStmt(), _copySubPlan(), _copyTargetEntry(), _copyTransactionStmt(), _copyTriggerTransition(), _copyUnlistenStmt(), _copyValue(), _copyVariableSetStmt(), _copyVariableShowStmt(), _copyWindowClause(), _copyWindowDef(), _copyWithCheckOption(), _copyXmlExpr(), and CopyCreateStmtFields().

Function Documentation

static A_ArrayExpr* _copyA_ArrayExpr ( const A_ArrayExpr from)
static

Definition at line 2601 of file copyfuncs.c.

References COPY_LOCATION_FIELD, COPY_NODE_FIELD, and makeNode.

Referenced by copyObjectImpl().

2602 {
2603  A_ArrayExpr *newnode = makeNode(A_ArrayExpr);
2604 
2605  COPY_NODE_FIELD(elements);
2606  COPY_LOCATION_FIELD(location);
2607 
2608  return newnode;
2609 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
static A_Indirection* _copyA_Indirection ( const A_Indirection from)
static

Definition at line 2590 of file copyfuncs.c.

References arg, COPY_NODE_FIELD, and makeNode.

Referenced by copyObjectImpl().

2591 {
2592  A_Indirection *newnode = makeNode(A_Indirection);
2593 
2595  COPY_NODE_FIELD(indirection);
2596 
2597  return newnode;
2598 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
void * arg
static AccessPriv* _copyAccessPriv ( const AccessPriv from)
static

Definition at line 3149 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

3150 {
3151  AccessPriv *newnode = makeNode(AccessPriv);
3152 
3153  COPY_STRING_FIELD(priv_name);
3154  COPY_NODE_FIELD(cols);
3155 
3156  return newnode;
3157 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static A_Const* _copyAConst ( const A_Const from)
static

Definition at line 2520 of file copyfuncs.c.

References COPY_LOCATION_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, elog, ERROR, makeNode, T_BitString, T_Float, T_Integer, T_Null, T_String, Value::type, A_Const::val, and val.

Referenced by copyObjectImpl().

2521 {
2522  A_Const *newnode = makeNode(A_Const);
2523 
2524  /* This part must duplicate _copyValue */
2525  COPY_SCALAR_FIELD(val.type);
2526  switch (from->val.type)
2527  {
2528  case T_Integer:
2529  COPY_SCALAR_FIELD(val.val.ival);
2530  break;
2531  case T_Float:
2532  case T_String:
2533  case T_BitString:
2534  COPY_STRING_FIELD(val.val.str);
2535  break;
2536  case T_Null:
2537  /* nothing to do */
2538  break;
2539  default:
2540  elog(ERROR, "unrecognized node type: %d",
2541  (int) from->val.type);
2542  break;
2543  }
2544 
2545  COPY_LOCATION_FIELD(location);
2546 
2547  return newnode;
2548 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define ERROR
Definition: elog.h:43
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
Definition: nodes.h:286
Definition: nodes.h:283
#define elog
Definition: elog.h:219
Value val
Definition: parsenodes.h:287
long val
Definition: informix.c:689
NodeTag type
Definition: value.h:44
static A_Expr* _copyAExpr ( const A_Expr from)
static

Definition at line 2484 of file copyfuncs.c.

References COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, makeNode, and name.

Referenced by copyObjectImpl().

2485 {
2486  A_Expr *newnode = makeNode(A_Expr);
2487 
2488  COPY_SCALAR_FIELD(kind);
2490  COPY_NODE_FIELD(lexpr);
2491  COPY_NODE_FIELD(rexpr);
2492  COPY_LOCATION_FIELD(location);
2493 
2494  return newnode;
2495 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
const char * name
Definition: encode.c:521
static Agg* _copyAgg ( const Agg from)
static

Definition at line 961 of file copyfuncs.c.

References COPY_BITMAPSET_FIELD, COPY_NODE_FIELD, COPY_POINTER_FIELD, COPY_SCALAR_FIELD, CopyPlanFields(), makeNode, and Agg::numCols.

Referenced by copyObjectImpl().

962 {
963  Agg *newnode = makeNode(Agg);
964 
965  CopyPlanFields((const Plan *) from, (Plan *) newnode);
966 
967  COPY_SCALAR_FIELD(aggstrategy);
968  COPY_SCALAR_FIELD(aggsplit);
969  COPY_SCALAR_FIELD(numCols);
970  if (from->numCols > 0)
971  {
972  COPY_POINTER_FIELD(grpColIdx, from->numCols * sizeof(AttrNumber));
973  COPY_POINTER_FIELD(grpOperators, from->numCols * sizeof(Oid));
974  }
975  COPY_SCALAR_FIELD(numGroups);
976  COPY_BITMAPSET_FIELD(aggParams);
977  COPY_NODE_FIELD(groupingSets);
978  COPY_NODE_FIELD(chain);
979 
980  return newnode;
981 }
#define COPY_BITMAPSET_FIELD(fldname)
Definition: copyfuncs.c:49
int numCols
Definition: plannodes.h:785
unsigned int Oid
Definition: postgres_ext.h:31
#define COPY_POINTER_FIELD(fldname, sz)
Definition: copyfuncs.c:57
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
static void CopyPlanFields(const Plan *from, Plan *newnode)
Definition: copyfuncs.c:115
#define makeNode(_type_)
Definition: nodes.h:557
Definition: plannodes.h:780
int16 AttrNumber
Definition: attnum.h:21
static Aggref* _copyAggref ( const Aggref from)
static

Definition at line 1349 of file copyfuncs.c.

References generate_unaccent_rules::args, COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

1350 {
1351  Aggref *newnode = makeNode(Aggref);
1352 
1353  COPY_SCALAR_FIELD(aggfnoid);
1354  COPY_SCALAR_FIELD(aggtype);
1355  COPY_SCALAR_FIELD(aggcollid);
1356  COPY_SCALAR_FIELD(inputcollid);
1357  COPY_SCALAR_FIELD(aggtranstype);
1358  COPY_NODE_FIELD(aggargtypes);
1359  COPY_NODE_FIELD(aggdirectargs);
1361  COPY_NODE_FIELD(aggorder);
1362  COPY_NODE_FIELD(aggdistinct);
1363  COPY_NODE_FIELD(aggfilter);
1364  COPY_SCALAR_FIELD(aggstar);
1365  COPY_SCALAR_FIELD(aggvariadic);
1366  COPY_SCALAR_FIELD(aggkind);
1367  COPY_SCALAR_FIELD(agglevelsup);
1368  COPY_SCALAR_FIELD(aggsplit);
1369  COPY_LOCATION_FIELD(location);
1370 
1371  return newnode;
1372 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
static A_Indices* _copyAIndices ( const A_Indices from)
static

Definition at line 2578 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

2579 {
2580  A_Indices *newnode = makeNode(A_Indices);
2581 
2582  COPY_SCALAR_FIELD(is_slice);
2583  COPY_NODE_FIELD(lidx);
2584  COPY_NODE_FIELD(uidx);
2585 
2586  return newnode;
2587 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static Alias* _copyAlias ( const Alias from)
static

Definition at line 1188 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

1189 {
1190  Alias *newnode = makeNode(Alias);
1191 
1192  COPY_STRING_FIELD(aliasname);
1193  COPY_NODE_FIELD(colnames);
1194 
1195  return newnode;
1196 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static AlterCollationStmt* _copyAlterCollationStmt ( const AlterCollationStmt from)
static

Definition at line 3095 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObjectImpl().

3096 {
3098 
3099  COPY_NODE_FIELD(collname);
3100 
3101  return newnode;
3102 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static AlterDatabaseSetStmt* _copyAlterDatabaseSetStmt ( const AlterDatabaseSetStmt from)
static

Definition at line 3738 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, dbname, and makeNode.

Referenced by copyObjectImpl().

3739 {
3741 
3743  COPY_NODE_FIELD(setstmt);
3744 
3745  return newnode;
3746 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
char * dbname
Definition: streamutil.c:38
static AlterDatabaseStmt* _copyAlterDatabaseStmt ( const AlterDatabaseStmt from)
static

Definition at line 3727 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, dbname, and makeNode.

Referenced by copyObjectImpl().

3728 {
3730 
3733 
3734  return newnode;
3735 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
char * dbname
Definition: streamutil.c:38
static AlterDefaultPrivilegesStmt* _copyAlterDefaultPrivilegesStmt ( const AlterDefaultPrivilegesStmt from)
static

Definition at line 3175 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObjectImpl().

3176 {
3178 
3180  COPY_NODE_FIELD(action);
3181 
3182  return newnode;
3183 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static AlterDomainStmt* _copyAlterDomainStmt ( const AlterDomainStmt from)
static

Definition at line 3105 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, makeNode, and name.

Referenced by copyObjectImpl().

3106 {
3108 
3109  COPY_SCALAR_FIELD(subtype);
3110  COPY_NODE_FIELD(typeName);
3112  COPY_NODE_FIELD(def);
3113  COPY_SCALAR_FIELD(behavior);
3114  COPY_SCALAR_FIELD(missing_ok);
3115 
3116  return newnode;
3117 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
const char * name
Definition: encode.c:521
static AlterEnumStmt* _copyAlterEnumStmt ( const AlterEnumStmt from)
static

Definition at line 3609 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

3610 {
3611  AlterEnumStmt *newnode = makeNode(AlterEnumStmt);
3612 
3613  COPY_NODE_FIELD(typeName);
3614  COPY_STRING_FIELD(oldVal);
3615  COPY_STRING_FIELD(newVal);
3616  COPY_STRING_FIELD(newValNeighbor);
3617  COPY_SCALAR_FIELD(newValIsAfter);
3618  COPY_SCALAR_FIELD(skipIfNewValExists);
3619 
3620  return newnode;
3621 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static AlterEventTrigStmt* _copyAlterEventTrigStmt ( const AlterEventTrigStmt from)
static

Definition at line 4155 of file copyfuncs.c.

References COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

4156 {
4158 
4159  COPY_STRING_FIELD(trigname);
4160  COPY_SCALAR_FIELD(tgenabled);
4161 
4162  return newnode;
4163 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static AlterExtensionContentsStmt* _copyAlterExtensionContentsStmt ( const AlterExtensionContentsStmt from)
static

Definition at line 3963 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

3964 {
3966 
3967  COPY_STRING_FIELD(extname);
3968  COPY_SCALAR_FIELD(action);
3969  COPY_SCALAR_FIELD(objtype);
3970  COPY_NODE_FIELD(object);
3971 
3972  return newnode;
3973 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static AlterExtensionStmt* _copyAlterExtensionStmt ( const AlterExtensionStmt from)
static

Definition at line 3952 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

3953 {
3955 
3956  COPY_STRING_FIELD(extname);
3958 
3959  return newnode;
3960 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static AlterFdwStmt* _copyAlterFdwStmt ( const AlterFdwStmt from)
static

Definition at line 3988 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

3989 {
3990  AlterFdwStmt *newnode = makeNode(AlterFdwStmt);
3991 
3992  COPY_STRING_FIELD(fdwname);
3993  COPY_NODE_FIELD(func_options);
3995 
3996  return newnode;
3997 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static AlterForeignServerStmt* _copyAlterForeignServerStmt ( const AlterForeignServerStmt from)
static

Definition at line 4015 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

4016 {
4018 
4019  COPY_STRING_FIELD(servername);
4020  COPY_STRING_FIELD(version);
4022  COPY_SCALAR_FIELD(has_version);
4023 
4024  return newnode;
4025 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static AlterFunctionStmt* _copyAlterFunctionStmt ( const AlterFunctionStmt from)
static

Definition at line 3428 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObjectImpl().

3429 {
3431 
3432  COPY_NODE_FIELD(func);
3433  COPY_NODE_FIELD(actions);
3434 
3435  return newnode;
3436 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static AlternativeSubPlan* _copyAlternativeSubPlan ( const AlternativeSubPlan from)
static

Definition at line 1613 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObjectImpl().

1614 {
1616 
1617  COPY_NODE_FIELD(subplans);
1618 
1619  return newnode;
1620 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static AlterObjectDependsStmt* _copyAlterObjectDependsStmt ( const AlterObjectDependsStmt from)
static

Definition at line 3466 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

3467 {
3469 
3470  COPY_SCALAR_FIELD(objectType);
3471  COPY_NODE_FIELD(relation);
3472  COPY_NODE_FIELD(object);
3473  COPY_NODE_FIELD(extname);
3474 
3475  return newnode;
3476 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static AlterObjectSchemaStmt* _copyAlterObjectSchemaStmt ( const AlterObjectSchemaStmt from)
static

Definition at line 3479 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

3480 {
3482 
3483  COPY_SCALAR_FIELD(objectType);
3484  COPY_NODE_FIELD(relation);
3485  COPY_NODE_FIELD(object);
3486  COPY_STRING_FIELD(newschema);
3487  COPY_SCALAR_FIELD(missing_ok);
3488 
3489  return newnode;
3490 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static AlterOperatorStmt* _copyAlterOperatorStmt ( const AlterOperatorStmt from)
static

Definition at line 3506 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObjectImpl().

3507 {
3509 
3510  COPY_NODE_FIELD(opername);
3512 
3513  return newnode;
3514 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static AlterOpFamilyStmt* _copyAlterOpFamilyStmt ( const AlterOpFamilyStmt from)
static

Definition at line 3703 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

3704 {
3706 
3707  COPY_NODE_FIELD(opfamilyname);
3708  COPY_STRING_FIELD(amname);
3709  COPY_SCALAR_FIELD(isDrop);
3710  COPY_NODE_FIELD(items);
3711 
3712  return newnode;
3713 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static AlterOwnerStmt* _copyAlterOwnerStmt ( const AlterOwnerStmt from)
static

Definition at line 3493 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

3494 {
3496 
3497  COPY_SCALAR_FIELD(objectType);
3498  COPY_NODE_FIELD(relation);
3499  COPY_NODE_FIELD(object);
3500  COPY_NODE_FIELD(newowner);
3501 
3502  return newnode;
3503 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static AlterPolicyStmt* _copyAlterPolicyStmt ( const AlterPolicyStmt from)
static

Definition at line 4403 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

4404 {
4406 
4407  COPY_STRING_FIELD(policy_name);
4408  COPY_NODE_FIELD(table);
4409  COPY_NODE_FIELD(roles);
4410  COPY_NODE_FIELD(qual);
4411  COPY_NODE_FIELD(with_check);
4412 
4413  return newnode;
4414 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static AlterPublicationStmt* _copyAlterPublicationStmt ( const AlterPublicationStmt from)
static

Definition at line 4493 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

4494 {
4496 
4497  COPY_STRING_FIELD(pubname);
4499  COPY_NODE_FIELD(tables);
4500  COPY_SCALAR_FIELD(for_all_tables);
4501  COPY_SCALAR_FIELD(tableAction);
4502 
4503  return newnode;
4504 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static AlterRoleSetStmt* _copyAlterRoleSetStmt ( const AlterRoleSetStmt from)
static

Definition at line 4205 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

4206 {
4208 
4209  COPY_NODE_FIELD(role);
4210  COPY_STRING_FIELD(database);
4211  COPY_NODE_FIELD(setstmt);
4212 
4213  return newnode;
4214 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static AlterRoleStmt* _copyAlterRoleStmt ( const AlterRoleStmt from)
static

Definition at line 4193 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

4194 {
4195  AlterRoleStmt *newnode = makeNode(AlterRoleStmt);
4196 
4197  COPY_NODE_FIELD(role);
4199  COPY_SCALAR_FIELD(action);
4200 
4201  return newnode;
4202 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static AlterSeqStmt* _copyAlterSeqStmt ( const AlterSeqStmt from)
static

Definition at line 3844 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

3845 {
3846  AlterSeqStmt *newnode = makeNode(AlterSeqStmt);
3847 
3848  COPY_NODE_FIELD(sequence);
3850  COPY_SCALAR_FIELD(for_identity);
3851  COPY_SCALAR_FIELD(missing_ok);
3852 
3853  return newnode;
3854 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static AlterSubscriptionStmt* _copyAlterSubscriptionStmt ( const AlterSubscriptionStmt from)
static

Definition at line 4520 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

4521 {
4523 
4524  COPY_SCALAR_FIELD(kind);
4525  COPY_STRING_FIELD(subname);
4526  COPY_STRING_FIELD(conninfo);
4527  COPY_NODE_FIELD(publication);
4529 
4530  return newnode;
4531 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static AlterSystemStmt* _copyAlterSystemStmt ( const AlterSystemStmt from)
static

Definition at line 3820 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObjectImpl().

3821 {
3823 
3824  COPY_NODE_FIELD(setstmt);
3825 
3826  return newnode;
3827 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static AlterTableCmd* _copyAlterTableCmd ( const AlterTableCmd from)
static

Definition at line 3080 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, makeNode, and name.

Referenced by copyObjectImpl().

3081 {
3082  AlterTableCmd *newnode = makeNode(AlterTableCmd);
3083 
3084  COPY_SCALAR_FIELD(subtype);
3086  COPY_NODE_FIELD(newowner);
3087  COPY_NODE_FIELD(def);
3088  COPY_SCALAR_FIELD(behavior);
3089  COPY_SCALAR_FIELD(missing_ok);
3090 
3091  return newnode;
3092 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
const char * name
Definition: encode.c:521
static AlterTableMoveAllStmt* _copyAlterTableMoveAllStmt ( const AlterTableMoveAllStmt from)
static

Definition at line 3926 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

3927 {
3929 
3930  COPY_STRING_FIELD(orig_tablespacename);
3931  COPY_SCALAR_FIELD(objtype);
3932  COPY_NODE_FIELD(roles);
3933  COPY_STRING_FIELD(new_tablespacename);
3934  COPY_SCALAR_FIELD(nowait);
3935 
3936  return newnode;
3937 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static AlterTableSpaceOptionsStmt* _copyAlterTableSpaceOptionsStmt ( const AlterTableSpaceOptionsStmt from)
static

Definition at line 3914 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

3915 {
3917 
3918  COPY_STRING_FIELD(tablespacename);
3920  COPY_SCALAR_FIELD(isReset);
3921 
3922  return newnode;
3923 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static AlterTableStmt* _copyAlterTableStmt ( const AlterTableStmt from)
static

Definition at line 3067 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

3068 {
3070 
3071  COPY_NODE_FIELD(relation);
3072  COPY_NODE_FIELD(cmds);
3073  COPY_SCALAR_FIELD(relkind);
3074  COPY_SCALAR_FIELD(missing_ok);
3075 
3076  return newnode;
3077 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static AlterTSConfigurationStmt* _copyAlterTSConfigurationStmt ( const AlterTSConfigurationStmt from)
static

Definition at line 4371 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

4372 {
4374 
4375  COPY_SCALAR_FIELD(kind);
4376  COPY_NODE_FIELD(cfgname);
4377  COPY_NODE_FIELD(tokentype);
4378  COPY_NODE_FIELD(dicts);
4379  COPY_SCALAR_FIELD(override);
4380  COPY_SCALAR_FIELD(replace);
4381  COPY_SCALAR_FIELD(missing_ok);
4382 
4383  return newnode;
4384 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static AlterTSDictionaryStmt* _copyAlterTSDictionaryStmt ( const AlterTSDictionaryStmt from)
static

Definition at line 4360 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObjectImpl().

4361 {
4363 
4364  COPY_NODE_FIELD(dictname);
4366 
4367  return newnode;
4368 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static AlterUserMappingStmt* _copyAlterUserMappingStmt ( const AlterUserMappingStmt from)
static

Definition at line 4041 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, makeNode, and user.

Referenced by copyObjectImpl().

4042 {
4044 
4046  COPY_STRING_FIELD(servername);
4048 
4049  return newnode;
4050 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static char * user
Definition: pg_regress.c:92
static Append* _copyAppend ( const Append from)
static

Definition at line 231 of file copyfuncs.c.

References COPY_NODE_FIELD, CopyPlanFields(), and makeNode.

Referenced by copyObjectImpl().

232 {
233  Append *newnode = makeNode(Append);
234 
235  /*
236  * copy node superclass fields
237  */
238  CopyPlanFields((const Plan *) from, (Plan *) newnode);
239 
240  /*
241  * copy remainder of node
242  */
243  COPY_NODE_FIELD(partitioned_rels);
244  COPY_NODE_FIELD(appendplans);
245 
246  return newnode;
247 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
static void CopyPlanFields(const Plan *from, Plan *newnode)
Definition: copyfuncs.c:115
#define makeNode(_type_)
Definition: nodes.h:557
static AppendRelInfo* _copyAppendRelInfo ( const AppendRelInfo from)
static

Definition at line 2235 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

2236 {
2237  AppendRelInfo *newnode = makeNode(AppendRelInfo);
2238 
2239  COPY_SCALAR_FIELD(parent_relid);
2240  COPY_SCALAR_FIELD(child_relid);
2241  COPY_SCALAR_FIELD(parent_reltype);
2242  COPY_SCALAR_FIELD(child_reltype);
2243  COPY_NODE_FIELD(translated_vars);
2244  COPY_SCALAR_FIELD(parent_reloid);
2245 
2246  return newnode;
2247 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static ArrayCoerceExpr* _copyArrayCoerceExpr ( const ArrayCoerceExpr from)
static

Definition at line 1694 of file copyfuncs.c.

References arg, COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

1695 {
1697 
1699  COPY_SCALAR_FIELD(elemfuncid);
1700  COPY_SCALAR_FIELD(resulttype);
1701  COPY_SCALAR_FIELD(resulttypmod);
1702  COPY_SCALAR_FIELD(resultcollid);
1703  COPY_SCALAR_FIELD(isExplicit);
1704  COPY_SCALAR_FIELD(coerceformat);
1705  COPY_LOCATION_FIELD(location);
1706 
1707  return newnode;
1708 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
void * arg
static ArrayExpr* _copyArrayExpr ( const ArrayExpr from)
static

Definition at line 1793 of file copyfuncs.c.

References COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

1794 {
1795  ArrayExpr *newnode = makeNode(ArrayExpr);
1796 
1797  COPY_SCALAR_FIELD(array_typeid);
1798  COPY_SCALAR_FIELD(array_collid);
1799  COPY_SCALAR_FIELD(element_typeid);
1800  COPY_NODE_FIELD(elements);
1801  COPY_SCALAR_FIELD(multidims);
1802  COPY_LOCATION_FIELD(location);
1803 
1804  return newnode;
1805 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
static ArrayRef* _copyArrayRef ( const ArrayRef from)
static

Definition at line 1417 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

1418 {
1419  ArrayRef *newnode = makeNode(ArrayRef);
1420 
1421  COPY_SCALAR_FIELD(refarraytype);
1422  COPY_SCALAR_FIELD(refelemtype);
1423  COPY_SCALAR_FIELD(reftypmod);
1424  COPY_SCALAR_FIELD(refcollid);
1425  COPY_NODE_FIELD(refupperindexpr);
1426  COPY_NODE_FIELD(reflowerindexpr);
1427  COPY_NODE_FIELD(refexpr);
1428  COPY_NODE_FIELD(refassgnexpr);
1429 
1430  return newnode;
1431 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static A_Star* _copyAStar ( const A_Star from)
static

Definition at line 2570 of file copyfuncs.c.

References makeNode.

Referenced by copyObjectImpl().

2571 {
2572  A_Star *newnode = makeNode(A_Star);
2573 
2574  return newnode;
2575 }
#define makeNode(_type_)
Definition: nodes.h:557
static BitmapAnd* _copyBitmapAnd ( const BitmapAnd from)
static

Definition at line 308 of file copyfuncs.c.

References COPY_NODE_FIELD, CopyPlanFields(), and makeNode.

Referenced by copyObjectImpl().

309 {
310  BitmapAnd *newnode = makeNode(BitmapAnd);
311 
312  /*
313  * copy node superclass fields
314  */
315  CopyPlanFields((const Plan *) from, (Plan *) newnode);
316 
317  /*
318  * copy remainder of node
319  */
320  COPY_NODE_FIELD(bitmapplans);
321 
322  return newnode;
323 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
static void CopyPlanFields(const Plan *from, Plan *newnode)
Definition: copyfuncs.c:115
#define makeNode(_type_)
Definition: nodes.h:557
static BitmapHeapScan* _copyBitmapHeapScan ( const BitmapHeapScan from)
static

Definition at line 543 of file copyfuncs.c.

References COPY_NODE_FIELD, CopyScanFields(), and makeNode.

Referenced by copyObjectImpl().

544 {
546 
547  /*
548  * copy node superclass fields
549  */
550  CopyScanFields((const Scan *) from, (Scan *) newnode);
551 
552  /*
553  * copy remainder of node
554  */
555  COPY_NODE_FIELD(bitmapqualorig);
556 
557  return newnode;
558 }
static void CopyScanFields(const Scan *from, Scan *newnode)
Definition: copyfuncs.c:403
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static BitmapIndexScan* _copyBitmapIndexScan ( const BitmapIndexScan from)
static

Definition at line 519 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, CopyScanFields(), and makeNode.

Referenced by copyObjectImpl().

520 {
522 
523  /*
524  * copy node superclass fields
525  */
526  CopyScanFields((const Scan *) from, (Scan *) newnode);
527 
528  /*
529  * copy remainder of node
530  */
531  COPY_SCALAR_FIELD(indexid);
532  COPY_SCALAR_FIELD(isshared);
533  COPY_NODE_FIELD(indexqual);
534  COPY_NODE_FIELD(indexqualorig);
535 
536  return newnode;
537 }
static void CopyScanFields(const Scan *from, Scan *newnode)
Definition: copyfuncs.c:403
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static BitmapOr* _copyBitmapOr ( const BitmapOr from)
static

Definition at line 329 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, CopyPlanFields(), and makeNode.

Referenced by copyObjectImpl().

330 {
331  BitmapOr *newnode = makeNode(BitmapOr);
332 
333  /*
334  * copy node superclass fields
335  */
336  CopyPlanFields((const Plan *) from, (Plan *) newnode);
337 
338  /*
339  * copy remainder of node
340  */
341  COPY_SCALAR_FIELD(isshared);
342  COPY_NODE_FIELD(bitmapplans);
343 
344  return newnode;
345 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
static void CopyPlanFields(const Plan *from, Plan *newnode)
Definition: copyfuncs.c:115
#define makeNode(_type_)
Definition: nodes.h:557
static BooleanTest* _copyBooleanTest ( const BooleanTest from)
static

Definition at line 1933 of file copyfuncs.c.

References arg, COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

1934 {
1935  BooleanTest *newnode = makeNode(BooleanTest);
1936 
1938  COPY_SCALAR_FIELD(booltesttype);
1939  COPY_LOCATION_FIELD(location);
1940 
1941  return newnode;
1942 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
void * arg
static BoolExpr* _copyBoolExpr ( const BoolExpr from)
static

Definition at line 1552 of file copyfuncs.c.

References generate_unaccent_rules::args, boolop(), COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

1553 {
1554  BoolExpr *newnode = makeNode(BoolExpr);
1555 
1558  COPY_LOCATION_FIELD(location);
1559 
1560  return newnode;
1561 }
Datum boolop(PG_FUNCTION_ARGS)
Definition: _int_bool.c:420
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
static CaseExpr* _copyCaseExpr ( const CaseExpr from)
static

Definition at line 1745 of file copyfuncs.c.

References arg, generate_unaccent_rules::args, COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

1746 {
1747  CaseExpr *newnode = makeNode(CaseExpr);
1748 
1749  COPY_SCALAR_FIELD(casetype);
1750  COPY_SCALAR_FIELD(casecollid);
1753  COPY_NODE_FIELD(defresult);
1754  COPY_LOCATION_FIELD(location);
1755 
1756  return newnode;
1757 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
void * arg
static CaseTestExpr* _copyCaseTestExpr ( const CaseTestExpr from)
static

Definition at line 1778 of file copyfuncs.c.

References COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

1779 {
1780  CaseTestExpr *newnode = makeNode(CaseTestExpr);
1781 
1782  COPY_SCALAR_FIELD(typeId);
1783  COPY_SCALAR_FIELD(typeMod);
1784  COPY_SCALAR_FIELD(collation);
1785 
1786  return newnode;
1787 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define makeNode(_type_)
Definition: nodes.h:557
static CaseWhen* _copyCaseWhen ( const CaseWhen from)
static

Definition at line 1763 of file copyfuncs.c.

References COPY_LOCATION_FIELD, COPY_NODE_FIELD, makeNode, and result.

Referenced by copyObjectImpl().

1764 {
1765  CaseWhen *newnode = makeNode(CaseWhen);
1766 
1767  COPY_NODE_FIELD(expr);
1769  COPY_LOCATION_FIELD(location);
1770 
1771  return newnode;
1772 }
return result
Definition: formatting.c:1633
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
static ClosePortalStmt* _copyClosePortalStmt ( const ClosePortalStmt from)
static

Definition at line 3198 of file copyfuncs.c.

References COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

3199 {
3201 
3202  COPY_STRING_FIELD(portalname);
3203 
3204  return newnode;
3205 }
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static ClusterStmt* _copyClusterStmt ( const ClusterStmt from)
static

Definition at line 3208 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, makeNode, and verbose.

Referenced by copyObjectImpl().

3209 {
3210  ClusterStmt *newnode = makeNode(ClusterStmt);
3211 
3212  COPY_NODE_FIELD(relation);
3213  COPY_STRING_FIELD(indexname);
3215 
3216  return newnode;
3217 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
static int verbose
Definition: pg_basebackup.c:84
#define makeNode(_type_)
Definition: nodes.h:557
static CoalesceExpr* _copyCoalesceExpr ( const CoalesceExpr from)
static

Definition at line 1846 of file copyfuncs.c.

References generate_unaccent_rules::args, COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

1847 {
1848  CoalesceExpr *newnode = makeNode(CoalesceExpr);
1849 
1850  COPY_SCALAR_FIELD(coalescetype);
1851  COPY_SCALAR_FIELD(coalescecollid);
1853  COPY_LOCATION_FIELD(location);
1854 
1855  return newnode;
1856 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
static CoerceToDomain* _copyCoerceToDomain ( const CoerceToDomain from)
static

Definition at line 1948 of file copyfuncs.c.

References arg, COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

1949 {
1951 
1953  COPY_SCALAR_FIELD(resulttype);
1954  COPY_SCALAR_FIELD(resulttypmod);
1955  COPY_SCALAR_FIELD(resultcollid);
1956  COPY_SCALAR_FIELD(coercionformat);
1957  COPY_LOCATION_FIELD(location);
1958 
1959  return newnode;
1960 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
void * arg
static CoerceToDomainValue* _copyCoerceToDomainValue ( const CoerceToDomainValue from)
static

Definition at line 1966 of file copyfuncs.c.

References COPY_LOCATION_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

1967 {
1969 
1970  COPY_SCALAR_FIELD(typeId);
1971  COPY_SCALAR_FIELD(typeMod);
1972  COPY_SCALAR_FIELD(collation);
1973  COPY_LOCATION_FIELD(location);
1974 
1975  return newnode;
1976 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
static CoerceViaIO* _copyCoerceViaIO ( const CoerceViaIO from)
static

Definition at line 1677 of file copyfuncs.c.

References arg, COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

1678 {
1679  CoerceViaIO *newnode = makeNode(CoerceViaIO);
1680 
1682  COPY_SCALAR_FIELD(resulttype);
1683  COPY_SCALAR_FIELD(resultcollid);
1684  COPY_SCALAR_FIELD(coerceformat);
1685  COPY_LOCATION_FIELD(location);
1686 
1687  return newnode;
1688 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
void * arg
static CollateClause* _copyCollateClause ( const CollateClause from)
static

Definition at line 2770 of file copyfuncs.c.

References arg, COPY_LOCATION_FIELD, COPY_NODE_FIELD, and makeNode.

Referenced by copyObjectImpl().

2771 {
2772  CollateClause *newnode = makeNode(CollateClause);
2773 
2775  COPY_NODE_FIELD(collname);
2776  COPY_LOCATION_FIELD(location);
2777 
2778  return newnode;
2779 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
void * arg
static CollateExpr* _copyCollateExpr ( const CollateExpr from)
static

Definition at line 1730 of file copyfuncs.c.

References arg, COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

1731 {
1732  CollateExpr *newnode = makeNode(CollateExpr);
1733 
1735  COPY_SCALAR_FIELD(collOid);
1736  COPY_LOCATION_FIELD(location);
1737 
1738  return newnode;
1739 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
void * arg
static ColumnDef* _copyColumnDef ( const ColumnDef from)
static

Definition at line 2798 of file copyfuncs.c.

References COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

2799 {
2800  ColumnDef *newnode = makeNode(ColumnDef);
2801 
2802  COPY_STRING_FIELD(colname);
2803  COPY_NODE_FIELD(typeName);
2804  COPY_SCALAR_FIELD(inhcount);
2805  COPY_SCALAR_FIELD(is_local);
2806  COPY_SCALAR_FIELD(is_not_null);
2807  COPY_SCALAR_FIELD(is_from_type);
2808  COPY_SCALAR_FIELD(is_from_parent);
2809  COPY_SCALAR_FIELD(storage);
2810  COPY_NODE_FIELD(raw_default);
2811  COPY_NODE_FIELD(cooked_default);
2812  COPY_SCALAR_FIELD(identity);
2813  COPY_NODE_FIELD(collClause);
2814  COPY_SCALAR_FIELD(collOid);
2815  COPY_NODE_FIELD(constraints);
2816  COPY_NODE_FIELD(fdwoptions);
2817  COPY_LOCATION_FIELD(location);
2818 
2819  return newnode;
2820 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
static ColumnRef* _copyColumnRef ( const ColumnRef from)
static

Definition at line 2498 of file copyfuncs.c.

References COPY_LOCATION_FIELD, COPY_NODE_FIELD, and makeNode.

Referenced by copyObjectImpl().

2499 {
2500  ColumnRef *newnode = makeNode(ColumnRef);
2501 
2502  COPY_NODE_FIELD(fields);
2503  COPY_LOCATION_FIELD(location);
2504 
2505  return newnode;
2506 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
static CommentStmt* _copyCommentStmt ( const CommentStmt from)
static

Definition at line 3320 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

3321 {
3322  CommentStmt *newnode = makeNode(CommentStmt);
3323 
3324  COPY_SCALAR_FIELD(objtype);
3325  COPY_NODE_FIELD(object);
3326  COPY_STRING_FIELD(comment);
3327 
3328  return newnode;
3329 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static CommonTableExpr* _copyCommonTableExpr ( const CommonTableExpr from)
static

Definition at line 2465 of file copyfuncs.c.

References COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

2466 {
2468 
2469  COPY_STRING_FIELD(ctename);
2470  COPY_NODE_FIELD(aliascolnames);
2471  COPY_NODE_FIELD(ctequery);
2472  COPY_LOCATION_FIELD(location);
2473  COPY_SCALAR_FIELD(cterecursive);
2474  COPY_SCALAR_FIELD(cterefcount);
2475  COPY_NODE_FIELD(ctecolnames);
2476  COPY_NODE_FIELD(ctecoltypes);
2477  COPY_NODE_FIELD(ctecoltypmods);
2478  COPY_NODE_FIELD(ctecolcollations);
2479 
2480  return newnode;
2481 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
static CompositeTypeStmt* _copyCompositeTypeStmt ( const CompositeTypeStmt from)
static

Definition at line 3576 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObjectImpl().

3577 {
3579 
3580  COPY_NODE_FIELD(typevar);
3581  COPY_NODE_FIELD(coldeflist);
3582 
3583  return newnode;
3584 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static Const* _copyConst ( const Const from)
static

Definition at line 1293 of file copyfuncs.c.

References Const::constbyval, Const::constisnull, Const::constlen, Const::constvalue, COPY_LOCATION_FIELD, COPY_SCALAR_FIELD, datumCopy(), and makeNode.

Referenced by copyObjectImpl().

1294 {
1295  Const *newnode = makeNode(Const);
1296 
1297  COPY_SCALAR_FIELD(consttype);
1298  COPY_SCALAR_FIELD(consttypmod);
1299  COPY_SCALAR_FIELD(constcollid);
1300  COPY_SCALAR_FIELD(constlen);
1301 
1302  if (from->constbyval || from->constisnull)
1303  {
1304  /*
1305  * passed by value so just copy the datum. Also, don't try to copy
1306  * struct when value is null!
1307  */
1308  newnode->constvalue = from->constvalue;
1309  }
1310  else
1311  {
1312  /*
1313  * passed by reference. We need a palloc'd copy.
1314  */
1315  newnode->constvalue = datumCopy(from->constvalue,
1316  from->constbyval,
1317  from->constlen);
1318  }
1319 
1320  COPY_SCALAR_FIELD(constisnull);
1321  COPY_SCALAR_FIELD(constbyval);
1322  COPY_LOCATION_FIELD(location);
1323 
1324  return newnode;
1325 }
Datum constvalue
Definition: primnodes.h:196
bool constbyval
Definition: primnodes.h:199
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
int constlen
Definition: primnodes.h:195
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
Datum datumCopy(Datum value, bool typByVal, int typLen)
Definition: datum.c:128
#define makeNode(_type_)
Definition: nodes.h:557
bool constisnull
Definition: primnodes.h:197
static Constraint* _copyConstraint ( const Constraint from)
static

Definition at line 2823 of file copyfuncs.c.

References COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

2824 {
2825  Constraint *newnode = makeNode(Constraint);
2826 
2827  COPY_SCALAR_FIELD(contype);
2828  COPY_STRING_FIELD(conname);
2829  COPY_SCALAR_FIELD(deferrable);
2830  COPY_SCALAR_FIELD(initdeferred);
2831  COPY_LOCATION_FIELD(location);
2832  COPY_SCALAR_FIELD(is_no_inherit);
2833  COPY_NODE_FIELD(raw_expr);
2834  COPY_STRING_FIELD(cooked_expr);
2835  COPY_SCALAR_FIELD(generated_when);
2836  COPY_NODE_FIELD(keys);
2837  COPY_NODE_FIELD(exclusions);
2839  COPY_STRING_FIELD(indexname);
2840  COPY_STRING_FIELD(indexspace);
2841  COPY_STRING_FIELD(access_method);
2842  COPY_NODE_FIELD(where_clause);
2843  COPY_NODE_FIELD(pktable);
2844  COPY_NODE_FIELD(fk_attrs);
2845  COPY_NODE_FIELD(pk_attrs);
2846  COPY_SCALAR_FIELD(fk_matchtype);
2847  COPY_SCALAR_FIELD(fk_upd_action);
2848  COPY_SCALAR_FIELD(fk_del_action);
2849  COPY_NODE_FIELD(old_conpfeqop);
2850  COPY_SCALAR_FIELD(old_pktable_oid);
2851  COPY_SCALAR_FIELD(skip_validation);
2852  COPY_SCALAR_FIELD(initially_valid);
2853 
2854  return newnode;
2855 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
static ConstraintsSetStmt* _copyConstraintsSetStmt ( const ConstraintsSetStmt from)
static

Definition at line 4240 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

4241 {
4243 
4244  COPY_NODE_FIELD(constraints);
4245  COPY_SCALAR_FIELD(deferred);
4246 
4247  return newnode;
4248 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static ConvertRowtypeExpr* _copyConvertRowtypeExpr ( const ConvertRowtypeExpr from)
static

Definition at line 1714 of file copyfuncs.c.

References arg, COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

1715 {
1717 
1719  COPY_SCALAR_FIELD(resulttype);
1720  COPY_SCALAR_FIELD(convertformat);
1721  COPY_LOCATION_FIELD(location);
1722 
1723  return newnode;
1724 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
void * arg
static CopyStmt* _copyCopyStmt ( const CopyStmt from)
static

Definition at line 3220 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, filename, and makeNode.

Referenced by copyObjectImpl().

3221 {
3222  CopyStmt *newnode = makeNode(CopyStmt);
3223 
3224  COPY_NODE_FIELD(relation);
3225  COPY_NODE_FIELD(query);
3226  COPY_NODE_FIELD(attlist);
3227  COPY_SCALAR_FIELD(is_from);
3228  COPY_SCALAR_FIELD(is_program);
3231 
3232  return newnode;
3233 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static char * filename
Definition: pg_dumpall.c:89
static CreateAmStmt* _copyCreateAmStmt ( const CreateAmStmt from)
static

Definition at line 4107 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

4108 {
4109  CreateAmStmt *newnode = makeNode(CreateAmStmt);
4110 
4111  COPY_STRING_FIELD(amname);
4112  COPY_NODE_FIELD(handler_name);
4113  COPY_SCALAR_FIELD(amtype);
4114 
4115  return newnode;
4116 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static CreateCastStmt* _copyCreateCastStmt ( const CreateCastStmt from)
static

Definition at line 4291 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

4292 {
4294 
4295  COPY_NODE_FIELD(sourcetype);
4296  COPY_NODE_FIELD(targettype);
4297  COPY_NODE_FIELD(func);
4298  COPY_SCALAR_FIELD(context);
4299  COPY_SCALAR_FIELD(inout);
4300 
4301  return newnode;
4302 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static CreateConversionStmt* _copyCreateConversionStmt ( const CreateConversionStmt from)
static

Definition at line 4277 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

4278 {
4280 
4281  COPY_NODE_FIELD(conversion_name);
4282  COPY_STRING_FIELD(for_encoding_name);
4283  COPY_STRING_FIELD(to_encoding_name);
4284  COPY_NODE_FIELD(func_name);
4285  COPY_SCALAR_FIELD(def);
4286 
4287  return newnode;
4288 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static CreatedbStmt* _copyCreatedbStmt ( const CreatedbStmt from)
static

Definition at line 3716 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, dbname, and makeNode.

Referenced by copyObjectImpl().

3717 {
3718  CreatedbStmt *newnode = makeNode(CreatedbStmt);
3719 
3722 
3723  return newnode;
3724 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
char * dbname
Definition: streamutil.c:38
static CreateDomainStmt* _copyCreateDomainStmt ( const CreateDomainStmt from)
static

Definition at line 3649 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObjectImpl().

3650 {
3652 
3653  COPY_NODE_FIELD(domainname);
3654  COPY_NODE_FIELD(typeName);
3655  COPY_NODE_FIELD(collClause);
3656  COPY_NODE_FIELD(constraints);
3657 
3658  return newnode;
3659 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static CreateEnumStmt* _copyCreateEnumStmt ( const CreateEnumStmt from)
static

Definition at line 3587 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObjectImpl().

3588 {
3590 
3591  COPY_NODE_FIELD(typeName);
3592  COPY_NODE_FIELD(vals);
3593 
3594  return newnode;
3595 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static CreateEventTrigStmt* _copyCreateEventTrigStmt ( const CreateEventTrigStmt from)
static

Definition at line 4142 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

4143 {
4145 
4146  COPY_STRING_FIELD(trigname);
4147  COPY_STRING_FIELD(eventname);
4148  COPY_NODE_FIELD(whenclause);
4149  COPY_NODE_FIELD(funcname);
4150 
4151  return newnode;
4152 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static CreateExtensionStmt* _copyCreateExtensionStmt ( const CreateExtensionStmt from)
static

Definition at line 3940 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

3941 {
3943 
3944  COPY_STRING_FIELD(extname);
3945  COPY_SCALAR_FIELD(if_not_exists);
3947 
3948  return newnode;
3949 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static CreateFdwStmt* _copyCreateFdwStmt ( const CreateFdwStmt from)
static

Definition at line 3976 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

3977 {
3978  CreateFdwStmt *newnode = makeNode(CreateFdwStmt);
3979 
3980  COPY_STRING_FIELD(fdwname);
3981  COPY_NODE_FIELD(func_options);
3983 
3984  return newnode;
3985 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static CreateForeignServerStmt* _copyCreateForeignServerStmt ( const CreateForeignServerStmt from)
static

Definition at line 4000 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

4001 {
4003 
4004  COPY_STRING_FIELD(servername);
4005  COPY_STRING_FIELD(servertype);
4006  COPY_STRING_FIELD(version);
4007  COPY_STRING_FIELD(fdwname);
4008  COPY_SCALAR_FIELD(if_not_exists);
4010 
4011  return newnode;
4012 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static CreateForeignTableStmt* _copyCreateForeignTableStmt ( const CreateForeignTableStmt from)
static

Definition at line 4065 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, CopyCreateStmtFields(), and makeNode.

Referenced by copyObjectImpl().

4066 {
4068 
4069  CopyCreateStmtFields((const CreateStmt *) from, (CreateStmt *) newnode);
4070 
4071  COPY_STRING_FIELD(servername);
4073 
4074  return newnode;
4075 }
static void CopyCreateStmtFields(const CreateStmt *from, CreateStmt *newnode)
Definition: copyfuncs.c:3242
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static CreateFunctionStmt* _copyCreateFunctionStmt ( const CreateFunctionStmt from)
static

Definition at line 3400 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

3401 {
3403 
3404  COPY_SCALAR_FIELD(replace);
3405  COPY_NODE_FIELD(funcname);
3406  COPY_NODE_FIELD(parameters);
3407  COPY_NODE_FIELD(returnType);
3409  COPY_NODE_FIELD(withClause);
3410 
3411  return newnode;
3412 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static CreateOpClassItem* _copyCreateOpClassItem ( const CreateOpClassItem from)
static

Definition at line 3677 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, makeNode, and name.

Referenced by copyObjectImpl().

3678 {
3680 
3681  COPY_SCALAR_FIELD(itemtype);
3683  COPY_SCALAR_FIELD(number);
3684  COPY_NODE_FIELD(order_family);
3685  COPY_NODE_FIELD(class_args);
3686  COPY_NODE_FIELD(storedtype);
3687 
3688  return newnode;
3689 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
const char * name
Definition: encode.c:521
static CreateOpClassStmt* _copyCreateOpClassStmt ( const CreateOpClassStmt from)
static

Definition at line 3662 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

3663 {
3665 
3666  COPY_NODE_FIELD(opclassname);
3667  COPY_NODE_FIELD(opfamilyname);
3668  COPY_STRING_FIELD(amname);
3669  COPY_NODE_FIELD(datatype);
3670  COPY_NODE_FIELD(items);
3671  COPY_SCALAR_FIELD(isDefault);
3672 
3673  return newnode;
3674 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static CreateOpFamilyStmt* _copyCreateOpFamilyStmt ( const CreateOpFamilyStmt from)
static

Definition at line 3692 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

3693 {
3695 
3696  COPY_NODE_FIELD(opfamilyname);
3697  COPY_STRING_FIELD(amname);
3698 
3699  return newnode;
3700 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static CreatePLangStmt* _copyCreatePLangStmt ( const CreatePLangStmt from)
static

Definition at line 4166 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

4167 {
4169 
4170  COPY_SCALAR_FIELD(replace);
4171  COPY_STRING_FIELD(plname);
4172  COPY_NODE_FIELD(plhandler);
4173  COPY_NODE_FIELD(plinline);
4174  COPY_NODE_FIELD(plvalidator);
4175  COPY_SCALAR_FIELD(pltrusted);
4176 
4177  return newnode;
4178 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static CreatePolicyStmt* _copyCreatePolicyStmt ( const CreatePolicyStmt from)
static

Definition at line 4387 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

4388 {
4390 
4391  COPY_STRING_FIELD(policy_name);
4392  COPY_NODE_FIELD(table);
4393  COPY_STRING_FIELD(cmd_name);
4394  COPY_SCALAR_FIELD(permissive);
4395  COPY_NODE_FIELD(roles);
4396  COPY_NODE_FIELD(qual);
4397  COPY_NODE_FIELD(with_check);
4398 
4399  return newnode;
4400 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static CreatePublicationStmt* _copyCreatePublicationStmt ( const CreatePublicationStmt from)
static

Definition at line 4480 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

4481 {
4483 
4484  COPY_STRING_FIELD(pubname);
4486  COPY_NODE_FIELD(tables);
4487  COPY_SCALAR_FIELD(for_all_tables);
4488 
4489  return newnode;
4490 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static CreateRangeStmt* _copyCreateRangeStmt ( const CreateRangeStmt from)
static

Definition at line 3598 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObjectImpl().

3599 {
3601 
3602  COPY_NODE_FIELD(typeName);
3603  COPY_NODE_FIELD(params);
3604 
3605  return newnode;
3606 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static CreateRoleStmt* _copyCreateRoleStmt ( const CreateRoleStmt from)
static

Definition at line 4181 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

4182 {
4184 
4185  COPY_SCALAR_FIELD(stmt_type);
4186  COPY_STRING_FIELD(role);
4188 
4189  return newnode;
4190 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static CreateSchemaStmt* _copyCreateSchemaStmt ( const CreateSchemaStmt from)
static

Definition at line 4264 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

4265 {
4267 
4268  COPY_STRING_FIELD(schemaname);
4269  COPY_NODE_FIELD(authrole);
4270  COPY_NODE_FIELD(schemaElts);
4271  COPY_SCALAR_FIELD(if_not_exists);
4272 
4273  return newnode;
4274 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static CreateSeqStmt* _copyCreateSeqStmt ( const CreateSeqStmt from)
static

Definition at line 3830 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

3831 {
3832  CreateSeqStmt *newnode = makeNode(CreateSeqStmt);
3833 
3834  COPY_NODE_FIELD(sequence);
3836  COPY_SCALAR_FIELD(ownerId);
3837  COPY_SCALAR_FIELD(for_identity);
3838  COPY_SCALAR_FIELD(if_not_exists);
3839 
3840  return newnode;
3841 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static CreateStatsStmt* _copyCreateStatsStmt ( const CreateStatsStmt from)
static

Definition at line 3386 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

3387 {
3389 
3390  COPY_NODE_FIELD(defnames);
3391  COPY_NODE_FIELD(stat_types);
3392  COPY_NODE_FIELD(exprs);
3393  COPY_NODE_FIELD(relations);
3394  COPY_SCALAR_FIELD(if_not_exists);
3395 
3396  return newnode;
3397 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static CreateStmt* _copyCreateStmt ( const CreateStmt from)
static

Definition at line 3258 of file copyfuncs.c.

References CopyCreateStmtFields(), and makeNode.

Referenced by copyObjectImpl().

3259 {
3260  CreateStmt *newnode = makeNode(CreateStmt);
3261 
3262  CopyCreateStmtFields(from, newnode);
3263 
3264  return newnode;
3265 }
static void CopyCreateStmtFields(const CreateStmt *from, CreateStmt *newnode)
Definition: copyfuncs.c:3242
#define makeNode(_type_)
Definition: nodes.h:557
static CreateSubscriptionStmt* _copyCreateSubscriptionStmt ( const CreateSubscriptionStmt from)
static

Definition at line 4507 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

4508 {
4510 
4511  COPY_STRING_FIELD(subname);
4512  COPY_STRING_FIELD(conninfo);
4513  COPY_NODE_FIELD(publication);
4515 
4516  return newnode;
4517 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static CreateTableAsStmt* _copyCreateTableAsStmt ( const CreateTableAsStmt from)
static

Definition at line 3783 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

3784 {
3786 
3787  COPY_NODE_FIELD(query);
3788  COPY_NODE_FIELD(into);
3789  COPY_SCALAR_FIELD(relkind);
3790  COPY_SCALAR_FIELD(is_select_into);
3791  COPY_SCALAR_FIELD(if_not_exists);
3792 
3793  return newnode;
3794 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static CreateTableSpaceStmt* _copyCreateTableSpaceStmt ( const CreateTableSpaceStmt from)
static

Definition at line 3890 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

3891 {
3893 
3894  COPY_STRING_FIELD(tablespacename);
3895  COPY_NODE_FIELD(owner);
3896  COPY_STRING_FIELD(location);
3898 
3899  return newnode;
3900 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static CreateTransformStmt* _copyCreateTransformStmt ( const CreateTransformStmt from)
static

Definition at line 4093 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

4094 {
4096 
4097  COPY_SCALAR_FIELD(replace);
4098  COPY_NODE_FIELD(type_name);
4099  COPY_STRING_FIELD(lang);
4100  COPY_NODE_FIELD(fromsql);
4101  COPY_NODE_FIELD(tosql);
4102 
4103  return newnode;
4104 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static CreateTrigStmt* _copyCreateTrigStmt ( const CreateTrigStmt from)
static

Definition at line 4119 of file copyfuncs.c.

References generate_unaccent_rules::args, COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

4120 {
4122 
4123  COPY_STRING_FIELD(trigname);
4124  COPY_NODE_FIELD(relation);
4125  COPY_NODE_FIELD(funcname);
4127  COPY_SCALAR_FIELD(row);
4128  COPY_SCALAR_FIELD(timing);
4129  COPY_SCALAR_FIELD(events);
4130  COPY_NODE_FIELD(columns);
4131  COPY_NODE_FIELD(whenClause);
4132  COPY_SCALAR_FIELD(isconstraint);
4133  COPY_NODE_FIELD(transitionRels);
4134  COPY_SCALAR_FIELD(deferrable);
4135  COPY_SCALAR_FIELD(initdeferred);
4136  COPY_NODE_FIELD(constrrel);
4137 
4138  return newnode;
4139 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static CreateUserMappingStmt* _copyCreateUserMappingStmt ( const CreateUserMappingStmt from)
static

Definition at line 4028 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, makeNode, and user.

Referenced by copyObjectImpl().

4029 {
4031 
4033  COPY_STRING_FIELD(servername);
4034  COPY_SCALAR_FIELD(if_not_exists);
4036 
4037  return newnode;
4038 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static char * user
Definition: pg_regress.c:92
static CteScan* _copyCteScan ( const CteScan from)
static

Definition at line 670 of file copyfuncs.c.

References COPY_SCALAR_FIELD, CopyScanFields(), and makeNode.

Referenced by copyObjectImpl().

671 {
672  CteScan *newnode = makeNode(CteScan);
673 
674  /*
675  * copy node superclass fields
676  */
677  CopyScanFields((const Scan *) from, (Scan *) newnode);
678 
679  /*
680  * copy remainder of node
681  */
682  COPY_SCALAR_FIELD(ctePlanId);
683  COPY_SCALAR_FIELD(cteParam);
684 
685  return newnode;
686 }
static void CopyScanFields(const Scan *from, Scan *newnode)
Definition: copyfuncs.c:403
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define makeNode(_type_)
Definition: nodes.h:557
static CurrentOfExpr* _copyCurrentOfExpr ( const CurrentOfExpr from)
static

Definition at line 1998 of file copyfuncs.c.

References COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

1999 {
2000  CurrentOfExpr *newnode = makeNode(CurrentOfExpr);
2001 
2002  COPY_SCALAR_FIELD(cvarno);
2003  COPY_STRING_FIELD(cursor_name);
2004  COPY_SCALAR_FIELD(cursor_param);
2005 
2006  return newnode;
2007 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static CustomScan* _copyCustomScan ( const CustomScan from)
static

Definition at line 762 of file copyfuncs.c.

References COPY_BITMAPSET_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, CopyScanFields(), and makeNode.

Referenced by copyObjectImpl().

763 {
764  CustomScan *newnode = makeNode(CustomScan);
765 
766  /*
767  * copy node superclass fields
768  */
769  CopyScanFields((const Scan *) from, (Scan *) newnode);
770 
771  /*
772  * copy remainder of node
773  */
774  COPY_SCALAR_FIELD(flags);
775  COPY_NODE_FIELD(custom_plans);
776  COPY_NODE_FIELD(custom_exprs);
777  COPY_NODE_FIELD(custom_private);
778  COPY_NODE_FIELD(custom_scan_tlist);
779  COPY_BITMAPSET_FIELD(custom_relids);
780 
781  /*
782  * NOTE: The method field of CustomScan is required to be a pointer to a
783  * static table of callback functions. So we don't copy the table itself,
784  * just reference the original one.
785  */
786  COPY_SCALAR_FIELD(methods);
787 
788  return newnode;
789 }
#define COPY_BITMAPSET_FIELD(fldname)
Definition: copyfuncs.c:49
static void CopyScanFields(const Scan *from, Scan *newnode)
Definition: copyfuncs.c:403
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static DeallocateStmt* _copyDeallocateStmt ( const DeallocateStmt from)
static

Definition at line 4328 of file copyfuncs.c.

References COPY_STRING_FIELD, makeNode, and name.

Referenced by copyObjectImpl().

4329 {
4331 
4333 
4334  return newnode;
4335 }
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
const char * name
Definition: encode.c:521
static DeclareCursorStmt* _copyDeclareCursorStmt ( const DeclareCursorStmt from)
static

Definition at line 3186 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

3187 {
3189 
3190  COPY_STRING_FIELD(portalname);
3192  COPY_NODE_FIELD(query);
3193 
3194  return newnode;
3195 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static DefElem* _copyDefElem ( const DefElem from)
static

Definition at line 2858 of file copyfuncs.c.

References arg, COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

2859 {
2860  DefElem *newnode = makeNode(DefElem);
2861 
2862  COPY_STRING_FIELD(defnamespace);
2863  COPY_STRING_FIELD(defname);
2865  COPY_SCALAR_FIELD(defaction);
2866  COPY_LOCATION_FIELD(location);
2867 
2868  return newnode;
2869 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
void * arg
static DefineStmt* _copyDefineStmt ( const DefineStmt from)
static

Definition at line 3279 of file copyfuncs.c.

References generate_unaccent_rules::args, COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

3280 {
3281  DefineStmt *newnode = makeNode(DefineStmt);
3282 
3283  COPY_SCALAR_FIELD(kind);
3284  COPY_SCALAR_FIELD(oldstyle);
3285  COPY_NODE_FIELD(defnames);
3287  COPY_NODE_FIELD(definition);
3288  COPY_SCALAR_FIELD(if_not_exists);
3289 
3290  return newnode;
3291 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static DeleteStmt* _copyDeleteStmt ( const DeleteStmt from)
static

Definition at line 2994 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObjectImpl().

2995 {
2996  DeleteStmt *newnode = makeNode(DeleteStmt);
2997 
2998  COPY_NODE_FIELD(relation);
2999  COPY_NODE_FIELD(usingClause);
3000  COPY_NODE_FIELD(whereClause);
3001  COPY_NODE_FIELD(returningList);
3002  COPY_NODE_FIELD(withClause);
3003 
3004  return newnode;
3005 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static DiscardStmt* _copyDiscardStmt ( const DiscardStmt from)
static

Definition at line 3880 of file copyfuncs.c.

References COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

3881 {
3882  DiscardStmt *newnode = makeNode(DiscardStmt);
3883 
3884  COPY_SCALAR_FIELD(target);
3885 
3886  return newnode;
3887 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define makeNode(_type_)
Definition: nodes.h:557
static DistinctExpr* _copyDistinctExpr ( const DistinctExpr from)
static

Definition at line 1494 of file copyfuncs.c.

References generate_unaccent_rules::args, COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

1495 {
1496  DistinctExpr *newnode = makeNode(DistinctExpr);
1497 
1498  COPY_SCALAR_FIELD(opno);
1499  COPY_SCALAR_FIELD(opfuncid);
1500  COPY_SCALAR_FIELD(opresulttype);
1501  COPY_SCALAR_FIELD(opretset);
1502  COPY_SCALAR_FIELD(opcollid);
1503  COPY_SCALAR_FIELD(inputcollid);
1505  COPY_LOCATION_FIELD(location);
1506 
1507  return newnode;
1508 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
static DoStmt* _copyDoStmt ( const DoStmt from)
static

Definition at line 3439 of file copyfuncs.c.

References generate_unaccent_rules::args, COPY_NODE_FIELD, and makeNode.

Referenced by copyObjectImpl().

3440 {
3441  DoStmt *newnode = makeNode(DoStmt);
3442 
3444 
3445  return newnode;
3446 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static DropdbStmt* _copyDropdbStmt ( const DropdbStmt from)
static

Definition at line 3749 of file copyfuncs.c.

References COPY_SCALAR_FIELD, COPY_STRING_FIELD, dbname, and makeNode.

Referenced by copyObjectImpl().

3750 {
3751  DropdbStmt *newnode = makeNode(DropdbStmt);
3752 
3754  COPY_SCALAR_FIELD(missing_ok);
3755 
3756  return newnode;
3757 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
char * dbname
Definition: streamutil.c:38
static DropOwnedStmt* _copyDropOwnedStmt ( const DropOwnedStmt from)
static

Definition at line 4338 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

4339 {
4340  DropOwnedStmt *newnode = makeNode(DropOwnedStmt);
4341 
4342  COPY_NODE_FIELD(roles);
4343  COPY_SCALAR_FIELD(behavior);
4344 
4345  return newnode;
4346 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static DropRoleStmt* _copyDropRoleStmt ( const DropRoleStmt from)
static

Definition at line 4217 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

4218 {
4219  DropRoleStmt *newnode = makeNode(DropRoleStmt);
4220 
4221  COPY_NODE_FIELD(roles);
4222  COPY_SCALAR_FIELD(missing_ok);
4223 
4224  return newnode;
4225 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static DropStmt* _copyDropStmt ( const DropStmt from)
static

Definition at line 3294 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

3295 {
3296  DropStmt *newnode = makeNode(DropStmt);
3297 
3298  COPY_NODE_FIELD(objects);
3299  COPY_SCALAR_FIELD(removeType);
3300  COPY_SCALAR_FIELD(behavior);
3301  COPY_SCALAR_FIELD(missing_ok);
3302  COPY_SCALAR_FIELD(concurrent);
3303 
3304  return newnode;
3305 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static DropSubscriptionStmt* _copyDropSubscriptionStmt ( const DropSubscriptionStmt from)
static

Definition at line 4534 of file copyfuncs.c.

References COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

4535 {
4537 
4538  COPY_STRING_FIELD(subname);
4539  COPY_SCALAR_FIELD(missing_ok);
4540  COPY_SCALAR_FIELD(behavior);
4541 
4542  return newnode;
4543 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static DropTableSpaceStmt* _copyDropTableSpaceStmt ( const DropTableSpaceStmt from)
static

Definition at line 3903 of file copyfuncs.c.

References COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

3904 {
3906 
3907  COPY_STRING_FIELD(tablespacename);
3908  COPY_SCALAR_FIELD(missing_ok);
3909 
3910  return newnode;
3911 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static DropUserMappingStmt* _copyDropUserMappingStmt ( const DropUserMappingStmt from)
static

Definition at line 4053 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, makeNode, and user.

Referenced by copyObjectImpl().

4054 {
4056 
4058  COPY_STRING_FIELD(servername);
4059  COPY_SCALAR_FIELD(missing_ok);
4060 
4061  return newnode;
4062 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static char * user
Definition: pg_regress.c:92
static ExecuteStmt* _copyExecuteStmt ( const ExecuteStmt from)
static

Definition at line 4317 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, makeNode, and name.

Referenced by copyObjectImpl().

4318 {
4319  ExecuteStmt *newnode = makeNode(ExecuteStmt);
4320 
4322  COPY_NODE_FIELD(params);
4323 
4324  return newnode;
4325 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
const char * name
Definition: encode.c:521
static ExplainStmt* _copyExplainStmt ( const ExplainStmt from)
static

Definition at line 3772 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObjectImpl().

3773 {
3774  ExplainStmt *newnode = makeNode(ExplainStmt);
3775 
3776  COPY_NODE_FIELD(query);
3778 
3779  return newnode;
3780 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static ExtensibleNode* _copyExtensibleNode ( const ExtensibleNode from)
static

Definition at line 4592 of file copyfuncs.c.

References COPY_STRING_FIELD, ExtensibleNode::extnodename, GetExtensibleNodeMethods(), newNode, ExtensibleNodeMethods::node_size, ExtensibleNodeMethods::nodeCopy, and T_ExtensibleNode.

Referenced by copyObjectImpl().

4593 {
4594  ExtensibleNode *newnode;
4595  const ExtensibleNodeMethods *methods;
4596 
4597  methods = GetExtensibleNodeMethods(from->extnodename, false);
4598  newnode = (ExtensibleNode *) newNode(methods->node_size,
4600  COPY_STRING_FIELD(extnodename);
4601 
4602  /* copy the private fields */
4603  methods->nodeCopy(newnode, from);
4604 
4605  return newnode;
4606 }
void(* nodeCopy)(struct ExtensibleNode *newnode, const struct ExtensibleNode *oldnode)
Definition: extensible.h:64
#define newNode(size, tag)
Definition: nodes.h:547
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
const char * extnodename
Definition: extensible.h:35
const ExtensibleNodeMethods * GetExtensibleNodeMethods(const char *extnodename, bool missing_ok)
Definition: extensible.c:125
static FetchStmt* _copyFetchStmt ( const FetchStmt from)
static

Definition at line 3345 of file copyfuncs.c.

References COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

3346 {
3347  FetchStmt *newnode = makeNode(FetchStmt);
3348 
3349  COPY_SCALAR_FIELD(direction);
3350  COPY_SCALAR_FIELD(howMany);
3351  COPY_STRING_FIELD(portalname);
3352  COPY_SCALAR_FIELD(ismove);
3353 
3354  return newnode;
3355 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static FieldSelect* _copyFieldSelect ( const FieldSelect from)
static

Definition at line 1626 of file copyfuncs.c.

References arg, COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

1627 {
1628  FieldSelect *newnode = makeNode(FieldSelect);
1629 
1631  COPY_SCALAR_FIELD(fieldnum);
1632  COPY_SCALAR_FIELD(resulttype);
1633  COPY_SCALAR_FIELD(resulttypmod);
1634  COPY_SCALAR_FIELD(resultcollid);
1635 
1636  return newnode;
1637 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
void * arg
static FieldStore* _copyFieldStore ( const FieldStore from)
static

Definition at line 1643 of file copyfuncs.c.

References arg, COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

1644 {
1645  FieldStore *newnode = makeNode(FieldStore);
1646 
1648  COPY_NODE_FIELD(newvals);
1649  COPY_NODE_FIELD(fieldnums);
1650  COPY_SCALAR_FIELD(resulttype);
1651 
1652  return newnode;
1653 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
void * arg
static ForeignKeyCacheInfo* _copyForeignKeyCacheInfo ( const ForeignKeyCacheInfo from)
static

Definition at line 4643 of file copyfuncs.c.

References ForeignKeyCacheInfo::confkey, ForeignKeyCacheInfo::conkey, ForeignKeyCacheInfo::conpfeqop, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

4644 {
4646 
4647  COPY_SCALAR_FIELD(conrelid);
4648  COPY_SCALAR_FIELD(confrelid);
4649  COPY_SCALAR_FIELD(nkeys);
4650  /* COPY_SCALAR_FIELD might work for these, but let's not assume that */
4651  memcpy(newnode->conkey, from->conkey, sizeof(newnode->conkey));
4652  memcpy(newnode->confkey, from->confkey, sizeof(newnode->confkey));
4653  memcpy(newnode->conpfeqop, from->conpfeqop, sizeof(newnode->conpfeqop));
4654 
4655  return newnode;
4656 }
AttrNumber conkey[INDEX_MAX_KEYS]
Definition: rel.h:243
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define makeNode(_type_)
Definition: nodes.h:557
Oid conpfeqop[INDEX_MAX_KEYS]
Definition: rel.h:245
AttrNumber confkey[INDEX_MAX_KEYS]
Definition: rel.h:244
static ForeignScan* _copyForeignScan ( const ForeignScan from)
static

Definition at line 734 of file copyfuncs.c.

References COPY_BITMAPSET_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, CopyScanFields(), and makeNode.

Referenced by copyObjectImpl().

735 {
736  ForeignScan *newnode = makeNode(ForeignScan);
737 
738  /*
739  * copy node superclass fields
740  */
741  CopyScanFields((const Scan *) from, (Scan *) newnode);
742 
743  /*
744  * copy remainder of node
745  */
746  COPY_SCALAR_FIELD(operation);
747  COPY_SCALAR_FIELD(fs_server);
748  COPY_NODE_FIELD(fdw_exprs);
749  COPY_NODE_FIELD(fdw_private);
750  COPY_NODE_FIELD(fdw_scan_tlist);
751  COPY_NODE_FIELD(fdw_recheck_quals);
752  COPY_BITMAPSET_FIELD(fs_relids);
753  COPY_SCALAR_FIELD(fsSystemCol);
754 
755  return newnode;
756 }
#define COPY_BITMAPSET_FIELD(fldname)
Definition: copyfuncs.c:49
static void CopyScanFields(const Scan *from, Scan *newnode)
Definition: copyfuncs.c:403
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static FromExpr* _copyFromExpr ( const FromExpr from)
static

Definition at line 2094 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObjectImpl().

2095 {
2096  FromExpr *newnode = makeNode(FromExpr);
2097 
2098  COPY_NODE_FIELD(fromlist);
2099  COPY_NODE_FIELD(quals);
2100 
2101  return newnode;
2102 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static FuncCall* _copyFuncCall ( const FuncCall from)
static

Definition at line 2551 of file copyfuncs.c.

References generate_unaccent_rules::args, COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

2552 {
2553  FuncCall *newnode = makeNode(FuncCall);
2554 
2555  COPY_NODE_FIELD(funcname);
2557  COPY_NODE_FIELD(agg_order);
2558  COPY_NODE_FIELD(agg_filter);
2559  COPY_SCALAR_FIELD(agg_within_group);
2560  COPY_SCALAR_FIELD(agg_star);
2561  COPY_SCALAR_FIELD(agg_distinct);
2562  COPY_SCALAR_FIELD(func_variadic);
2563  COPY_NODE_FIELD(over);
2564  COPY_LOCATION_FIELD(location);
2565 
2566  return newnode;
2567 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
static FuncExpr* _copyFuncExpr ( const FuncExpr from)
static

Definition at line 1437 of file copyfuncs.c.

References generate_unaccent_rules::args, COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

1438 {
1439  FuncExpr *newnode = makeNode(FuncExpr);
1440 
1441  COPY_SCALAR_FIELD(funcid);
1442  COPY_SCALAR_FIELD(funcresulttype);
1443  COPY_SCALAR_FIELD(funcretset);
1444  COPY_SCALAR_FIELD(funcvariadic);
1445  COPY_SCALAR_FIELD(funcformat);
1446  COPY_SCALAR_FIELD(funccollid);
1447  COPY_SCALAR_FIELD(inputcollid);
1449  COPY_LOCATION_FIELD(location);
1450 
1451  return newnode;
1452 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
static FunctionParameter* _copyFunctionParameter ( const FunctionParameter from)
static

Definition at line 3415 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, makeNode, and name.

Referenced by copyObjectImpl().

3416 {
3418 
3420  COPY_NODE_FIELD(argType);
3421  COPY_SCALAR_FIELD(mode);
3422  COPY_NODE_FIELD(defexpr);
3423 
3424  return newnode;
3425 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
const char * name
Definition: encode.c:521
static FunctionScan* _copyFunctionScan ( const FunctionScan from)
static

Definition at line 606 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, CopyScanFields(), functions, and makeNode.

Referenced by copyObjectImpl().

607 {
608  FunctionScan *newnode = makeNode(FunctionScan);
609 
610  /*
611  * copy node superclass fields
612  */
613  CopyScanFields((const Scan *) from, (Scan *) newnode);
614 
615  /*
616  * copy remainder of node
617  */
619  COPY_SCALAR_FIELD(funcordinality);
620 
621  return newnode;
622 }
static void CopyScanFields(const Scan *from, Scan *newnode)
Definition: copyfuncs.c:403
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static const struct fns functions
Definition: regcomp.c:299
static Gather* _copyGather ( const Gather from)
static

Definition at line 351 of file copyfuncs.c.

References COPY_SCALAR_FIELD, CopyPlanFields(), and makeNode.

Referenced by copyObjectImpl().

352 {
353  Gather *newnode = makeNode(Gather);
354 
355  /*
356  * copy node superclass fields
357  */
358  CopyPlanFields((const Plan *) from, (Plan *) newnode);
359 
360  /*
361  * copy remainder of node
362  */
363  COPY_SCALAR_FIELD(num_workers);
364  COPY_SCALAR_FIELD(single_copy);
365  COPY_SCALAR_FIELD(invisible);
366 
367  return newnode;
368 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
static void CopyPlanFields(const Plan *from, Plan *newnode)
Definition: copyfuncs.c:115
#define makeNode(_type_)
Definition: nodes.h:557
static GatherMerge* _copyGatherMerge ( const GatherMerge from)
static

Definition at line 374 of file copyfuncs.c.

References COPY_POINTER_FIELD, COPY_SCALAR_FIELD, CopyPlanFields(), makeNode, and GatherMerge::numCols.

Referenced by copyObjectImpl().

375 {
376  GatherMerge *newnode = makeNode(GatherMerge);
377 
378  /*
379  * copy node superclass fields
380  */
381  CopyPlanFields((const Plan *) from, (Plan *) newnode);
382 
383  /*
384  * copy remainder of node
385  */
386  COPY_SCALAR_FIELD(num_workers);
387  COPY_SCALAR_FIELD(numCols);
388  COPY_POINTER_FIELD(sortColIdx, from->numCols * sizeof(AttrNumber));
389  COPY_POINTER_FIELD(sortOperators, from->numCols * sizeof(Oid));
390  COPY_POINTER_FIELD(collations, from->numCols * sizeof(Oid));
391  COPY_POINTER_FIELD(nullsFirst, from->numCols * sizeof(bool));
392 
393  return newnode;
394 }
unsigned int Oid
Definition: postgres_ext.h:31
#define COPY_POINTER_FIELD(fldname, sz)
Definition: copyfuncs.c:57
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
static void CopyPlanFields(const Plan *from, Plan *newnode)
Definition: copyfuncs.c:115
#define makeNode(_type_)
Definition: nodes.h:557
int16 AttrNumber
Definition: attnum.h:21
static GrantRoleStmt* _copyGrantRoleStmt ( const GrantRoleStmt from)
static

Definition at line 3160 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

3161 {
3162  GrantRoleStmt *newnode = makeNode(GrantRoleStmt);
3163 
3164  COPY_NODE_FIELD(granted_roles);
3165  COPY_NODE_FIELD(grantee_roles);
3166  COPY_SCALAR_FIELD(is_grant);
3167  COPY_SCALAR_FIELD(admin_opt);
3168  COPY_NODE_FIELD(grantor);
3169  COPY_SCALAR_FIELD(behavior);
3170 
3171  return newnode;
3172 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static GrantStmt* _copyGrantStmt ( const GrantStmt from)
static

Definition at line 3120 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

3121 {
3122  GrantStmt *newnode = makeNode(GrantStmt);
3123 
3124  COPY_SCALAR_FIELD(is_grant);
3125  COPY_SCALAR_FIELD(targtype);
3126  COPY_SCALAR_FIELD(objtype);
3127  COPY_NODE_FIELD(objects);
3128  COPY_NODE_FIELD(privileges);
3129  COPY_NODE_FIELD(grantees);
3130  COPY_SCALAR_FIELD(grant_option);
3131  COPY_SCALAR_FIELD(behavior);
3132 
3133  return newnode;
3134 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static Group* _copyGroup ( const Group from)
static

Definition at line 944 of file copyfuncs.c.

References COPY_POINTER_FIELD, COPY_SCALAR_FIELD, CopyPlanFields(), makeNode, and Group::numCols.

Referenced by copyObjectImpl().

945 {
946  Group *newnode = makeNode(Group);
947 
948  CopyPlanFields((const Plan *) from, (Plan *) newnode);
949 
950  COPY_SCALAR_FIELD(numCols);
951  COPY_POINTER_FIELD(grpColIdx, from->numCols * sizeof(AttrNumber));
952  COPY_POINTER_FIELD(grpOperators, from->numCols * sizeof(Oid));
953 
954  return newnode;
955 }
unsigned int Oid
Definition: postgres_ext.h:31
#define COPY_POINTER_FIELD(fldname, sz)
Definition: copyfuncs.c:57
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
static void CopyPlanFields(const Plan *from, Plan *newnode)
Definition: copyfuncs.c:115
int numCols
Definition: plannodes.h:761
#define makeNode(_type_)
Definition: nodes.h:557
int16 AttrNumber
Definition: attnum.h:21
static GroupingFunc* _copyGroupingFunc ( const GroupingFunc from)
static

Definition at line 1378 of file copyfuncs.c.

References generate_unaccent_rules::args, COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

1379 {
1380  GroupingFunc *newnode = makeNode(GroupingFunc);
1381 
1383  COPY_NODE_FIELD(refs);
1384  COPY_NODE_FIELD(cols);
1385  COPY_SCALAR_FIELD(agglevelsup);
1386  COPY_LOCATION_FIELD(location);
1387 
1388  return newnode;
1389 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
static GroupingSet* _copyGroupingSet ( const GroupingSet from)
static

Definition at line 2383 of file copyfuncs.c.

References COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

2384 {
2385  GroupingSet *newnode = makeNode(GroupingSet);
2386 
2387  COPY_SCALAR_FIELD(kind);
2388  COPY_NODE_FIELD(content);
2389  COPY_LOCATION_FIELD(location);
2390 
2391  return newnode;
2392 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
static Hash* _copyHash ( const Hash from)
static

Definition at line 1040 of file copyfuncs.c.

References COPY_SCALAR_FIELD, CopyPlanFields(), and makeNode.

Referenced by copyObjectImpl().

1041 {
1042  Hash *newnode = makeNode(Hash);
1043 
1044  /*
1045  * copy node superclass fields
1046  */
1047  CopyPlanFields((const Plan *) from, (Plan *) newnode);
1048 
1049  /*
1050  * copy remainder of node
1051  */
1052  COPY_SCALAR_FIELD(skewTable);
1053  COPY_SCALAR_FIELD(skewColumn);
1054  COPY_SCALAR_FIELD(skewInherit);
1055 
1056  return newnode;
1057 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
static void CopyPlanFields(const Plan *from, Plan *newnode)
Definition: copyfuncs.c:115
#define makeNode(_type_)
Definition: nodes.h:557
static HashJoin* _copyHashJoin ( const HashJoin from)
static

Definition at line 882 of file copyfuncs.c.

References COPY_NODE_FIELD, CopyJoinFields(), and makeNode.

Referenced by copyObjectImpl().

883 {
884  HashJoin *newnode = makeNode(HashJoin);
885 
886  /*
887  * copy node superclass fields
888  */
889  CopyJoinFields((const Join *) from, (Join *) newnode);
890 
891  /*
892  * copy remainder of node
893  */
894  COPY_NODE_FIELD(hashclauses);
895 
896  return newnode;
897 }
static void CopyJoinFields(const Join *from, Join *newnode)
Definition: copyfuncs.c:798
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static ImportForeignSchemaStmt* _copyImportForeignSchemaStmt ( const ImportForeignSchemaStmt from)
static

Definition at line 4078 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

4079 {
4081 
4082  COPY_STRING_FIELD(server_name);
4083  COPY_STRING_FIELD(remote_schema);
4084  COPY_STRING_FIELD(local_schema);
4085  COPY_SCALAR_FIELD(list_type);
4086  COPY_NODE_FIELD(table_list);
4088 
4089  return newnode;
4090 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static IndexElem* _copyIndexElem ( const IndexElem from)
static

Definition at line 2782 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, makeNode, and name.

Referenced by copyObjectImpl().

2783 {
2784  IndexElem *newnode = makeNode(IndexElem);
2785 
2787  COPY_NODE_FIELD(expr);
2788  COPY_STRING_FIELD(indexcolname);
2789  COPY_NODE_FIELD(collation);
2790  COPY_NODE_FIELD(opclass);
2791  COPY_SCALAR_FIELD(ordering);
2792  COPY_SCALAR_FIELD(nulls_ordering);
2793 
2794  return newnode;
2795 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
const char * name
Definition: encode.c:521
static IndexOnlyScan* _copyIndexOnlyScan ( const IndexOnlyScan from)
static

Definition at line 494 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, CopyScanFields(), and makeNode.

Referenced by copyObjectImpl().

495 {
497 
498  /*
499  * copy node superclass fields
500  */
501  CopyScanFields((const Scan *) from, (Scan *) newnode);
502 
503  /*
504  * copy remainder of node
505  */
506  COPY_SCALAR_FIELD(indexid);
507  COPY_NODE_FIELD(indexqual);
508  COPY_NODE_FIELD(indexorderby);
509  COPY_NODE_FIELD(indextlist);
510  COPY_SCALAR_FIELD(indexorderdir);
511 
512  return newnode;
513 }
static void CopyScanFields(const Scan *from, Scan *newnode)
Definition: copyfuncs.c:403
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static IndexScan* _copyIndexScan ( const IndexScan from)
static

Definition at line 467 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, CopyScanFields(), and makeNode.

Referenced by copyObjectImpl().

468 {
469  IndexScan *newnode = makeNode(IndexScan);
470 
471  /*
472  * copy node superclass fields
473  */
474  CopyScanFields((const Scan *) from, (Scan *) newnode);
475 
476  /*
477  * copy remainder of node
478  */
479  COPY_SCALAR_FIELD(indexid);
480  COPY_NODE_FIELD(indexqual);
481  COPY_NODE_FIELD(indexqualorig);
482  COPY_NODE_FIELD(indexorderby);
483  COPY_NODE_FIELD(indexorderbyorig);
484  COPY_NODE_FIELD(indexorderbyops);
485  COPY_SCALAR_FIELD(indexorderdir);
486 
487  return newnode;
488 }
static void CopyScanFields(const Scan *from, Scan *newnode)
Definition: copyfuncs.c:403
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static IndexStmt* _copyIndexStmt ( const IndexStmt from)
static

Definition at line 3358 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

3359 {
3360  IndexStmt *newnode = makeNode(IndexStmt);
3361 
3362  COPY_STRING_FIELD(idxname);
3363  COPY_NODE_FIELD(relation);
3364  COPY_STRING_FIELD(accessMethod);
3365  COPY_STRING_FIELD(tableSpace);
3366  COPY_NODE_FIELD(indexParams);
3368  COPY_NODE_FIELD(whereClause);
3369  COPY_NODE_FIELD(excludeOpNames);
3370  COPY_STRING_FIELD(idxcomment);
3371  COPY_SCALAR_FIELD(indexOid);
3372  COPY_SCALAR_FIELD(oldNode);
3373  COPY_SCALAR_FIELD(unique);
3374  COPY_SCALAR_FIELD(primary);
3375  COPY_SCALAR_FIELD(isconstraint);
3376  COPY_SCALAR_FIELD(deferrable);
3377  COPY_SCALAR_FIELD(initdeferred);
3378  COPY_SCALAR_FIELD(transformed);
3379  COPY_SCALAR_FIELD(concurrent);
3380  COPY_SCALAR_FIELD(if_not_exists);
3381 
3382  return newnode;
3383 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static InferClause* _copyInferClause ( const InferClause from)
static

Definition at line 2438 of file copyfuncs.c.

References COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

2439 {
2440  InferClause *newnode = makeNode(InferClause);
2441 
2442  COPY_NODE_FIELD(indexElems);
2443  COPY_NODE_FIELD(whereClause);
2444  COPY_STRING_FIELD(conname);
2445  COPY_LOCATION_FIELD(location);
2446 
2447  return newnode;
2448 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
static InferenceElem* _copyInferenceElem ( const InferenceElem from)
static

Definition at line 2027 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

2028 {
2029  InferenceElem *newnode = makeNode(InferenceElem);
2030 
2031  COPY_NODE_FIELD(expr);
2032  COPY_SCALAR_FIELD(infercollid);
2033  COPY_SCALAR_FIELD(inferopclass);
2034 
2035  return newnode;
2036 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static InsertStmt* _copyInsertStmt ( const InsertStmt from)
static

Definition at line 2978 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

2979 {
2980  InsertStmt *newnode = makeNode(InsertStmt);
2981 
2982  COPY_NODE_FIELD(relation);
2983  COPY_NODE_FIELD(cols);
2984  COPY_NODE_FIELD(selectStmt);
2985  COPY_NODE_FIELD(onConflictClause);
2986  COPY_NODE_FIELD(returningList);
2987  COPY_NODE_FIELD(withClause);
2988  COPY_SCALAR_FIELD(override);
2989 
2990  return newnode;
2991 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static IntoClause* _copyIntoClause ( const IntoClause from)
static

Definition at line 1246 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

1247 {
1248  IntoClause *newnode = makeNode(IntoClause);
1249 
1250  COPY_NODE_FIELD(rel);
1251  COPY_NODE_FIELD(colNames);
1253  COPY_SCALAR_FIELD(onCommit);
1254  COPY_STRING_FIELD(tableSpaceName);
1255  COPY_NODE_FIELD(viewQuery);
1256  COPY_SCALAR_FIELD(skipData);
1257 
1258  return newnode;
1259 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static Join* _copyJoin ( const Join from)
static

Definition at line 812 of file copyfuncs.c.

References CopyJoinFields(), and makeNode.

Referenced by copyObjectImpl().

813 {
814  Join *newnode = makeNode(Join);
815 
816  /*
817  * copy node superclass fields
818  */
819  CopyJoinFields(from, newnode);
820 
821  return newnode;
822 }
static void CopyJoinFields(const Join *from, Join *newnode)
Definition: copyfuncs.c:798
#define makeNode(_type_)
Definition: nodes.h:557
static JoinExpr* _copyJoinExpr ( const JoinExpr from)
static

Definition at line 2074 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

2075 {
2076  JoinExpr *newnode = makeNode(JoinExpr);
2077 
2078  COPY_SCALAR_FIELD(jointype);
2079  COPY_SCALAR_FIELD(isNatural);
2080  COPY_NODE_FIELD(larg);
2081  COPY_NODE_FIELD(rarg);
2082  COPY_NODE_FIELD(usingClause);
2083  COPY_NODE_FIELD(quals);
2084  COPY_NODE_FIELD(alias);
2085  COPY_SCALAR_FIELD(rtindex);
2086 
2087  return newnode;
2088 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static Limit* _copyLimit ( const Limit from)
static

Definition at line 1113 of file copyfuncs.c.

References COPY_NODE_FIELD, CopyPlanFields(), and makeNode.

Referenced by copyObjectImpl().

1114 {
1115  Limit *newnode = makeNode(Limit);
1116 
1117  /*
1118  * copy node superclass fields
1119  */
1120  CopyPlanFields((const Plan *) from, (Plan *) newnode);
1121 
1122  /*
1123  * copy remainder of node
1124  */
1125  COPY_NODE_FIELD(limitOffset);
1126  COPY_NODE_FIELD(limitCount);
1127 
1128  return newnode;
1129 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
static void CopyPlanFields(const Plan *from, Plan *newnode)
Definition: copyfuncs.c:115
#define makeNode(_type_)
Definition: nodes.h:557
static List* _copyList ( const List from)
static

Definition at line 4560 of file copyfuncs.c.

References Assert, COPY_NODE_CELL, List::head, List::length, list_length(), lnext, makeNode, ListCell::next, and NULL.

Referenced by copyObjectImpl().

4561 {
4562  List *new;
4563  ListCell *curr_old;
4564  ListCell *prev_new;
4565 
4566  Assert(list_length(from) >= 1);
4567 
4568  new = makeNode(List);
4569  new->length = from->length;
4570 
4571  COPY_NODE_CELL(new->head, from->head);
4572  prev_new = new->head;
4573  curr_old = lnext(from->head);
4574 
4575  while (curr_old)
4576  {
4577  COPY_NODE_CELL(prev_new->next, curr_old);
4578  prev_new = prev_new->next;
4579  curr_old = curr_old->next;
4580  }
4581  prev_new->next = NULL;
4582  new->tail = prev_new;
4583 
4584  return new;
4585 }
#define lnext(lc)
Definition: pg_list.h:105
#define COPY_NODE_CELL(new, old)
Definition: copyfuncs.c:4555
#define makeNode(_type_)
Definition: nodes.h:557
ListCell * next
Definition: pg_list.h:61
#define NULL
Definition: c.h:229
#define Assert(condition)
Definition: c.h:675
static int list_length(const List *l)
Definition: pg_list.h:89
int length
Definition: pg_list.h:48
ListCell * head
Definition: pg_list.h:49
Definition: pg_list.h:45
static ListenStmt* _copyListenStmt ( const ListenStmt from)
static

Definition at line 3544 of file copyfuncs.c.

References COPY_STRING_FIELD, and makeNode.

Referenced by copyObjectImpl().

3545 {
3546  ListenStmt *newnode = makeNode(ListenStmt);
3547 
3548  COPY_STRING_FIELD(conditionname);
3549 
3550  return newnode;
3551 }
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static LoadStmt* _copyLoadStmt ( const LoadStmt from)
static

Definition at line 3639 of file copyfuncs.c.

References COPY_STRING_FIELD, filename, and makeNode.

Referenced by copyObjectImpl().

3640 {
3641  LoadStmt *newnode = makeNode(LoadStmt);
3642 
3644 
3645  return newnode;
3646 }
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:557
static char * filename
Definition: pg_dumpall.c:89
static LockingClause* _copyLockingClause ( const LockingClause from)
static

Definition at line 2872 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

2873 {
2874  LockingClause *newnode = makeNode(LockingClause);
2875 
2876  COPY_NODE_FIELD(lockedRels);
2877  COPY_SCALAR_FIELD(strength);
2878  COPY_SCALAR_FIELD(waitPolicy);
2879 
2880  return newnode;
2881 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static LockRows* _copyLockRows ( const LockRows from)
static

Definition at line 1091 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, CopyPlanFields(), and makeNode.

Referenced by copyObjectImpl().

1092 {
1093  LockRows *newnode = makeNode(LockRows);
1094 
1095  /*
1096  * copy node superclass fields
1097  */
1098  CopyPlanFields((const Plan *) from, (Plan *) newnode);
1099 
1100  /*
1101  * copy remainder of node
1102  */
1103  COPY_NODE_FIELD(rowMarks);
1104  COPY_SCALAR_FIELD(epqParam);
1105 
1106  return newnode;
1107 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
static void CopyPlanFields(const Plan *from, Plan *newnode)
Definition: copyfuncs.c:115
#define makeNode(_type_)
Definition: nodes.h:557
static LockStmt* _copyLockStmt ( const LockStmt from)
static

Definition at line 4228 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

4229 {
4230  LockStmt *newnode = makeNode(LockStmt);
4231 
4232  COPY_NODE_FIELD(relations);
4233  COPY_SCALAR_FIELD(mode);
4234  COPY_SCALAR_FIELD(nowait);
4235 
4236  return newnode;
4237 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static Material* _copyMaterial ( const Material from)
static

Definition at line 904 of file copyfuncs.c.

References CopyPlanFields(), and makeNode.

Referenced by copyObjectImpl().

905 {
906  Material *newnode = makeNode(Material);
907 
908  /*
909  * copy node superclass fields
910  */
911  CopyPlanFields((const Plan *) from, (Plan *) newnode);
912 
913  return newnode;
914 }
static void CopyPlanFields(const Plan *from, Plan *newnode)
Definition: copyfuncs.c:115
#define makeNode(_type_)
Definition: nodes.h:557
static MergeAppend* _copyMergeAppend ( const MergeAppend from)
static

Definition at line 253 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_POINTER_FIELD, COPY_SCALAR_FIELD, CopyPlanFields(), makeNode, and MergeAppend::numCols.

Referenced by copyObjectImpl().

254 {
255  MergeAppend *newnode = makeNode(MergeAppend);
256 
257  /*
258  * copy node superclass fields
259  */
260  CopyPlanFields((const Plan *) from, (Plan *) newnode);
261 
262  /*
263  * copy remainder of node
264  */
265  COPY_NODE_FIELD(partitioned_rels);
266  COPY_NODE_FIELD(mergeplans);
267  COPY_SCALAR_FIELD(numCols);
268  COPY_POINTER_FIELD(sortColIdx, from->numCols * sizeof(AttrNumber));
269  COPY_POINTER_FIELD(sortOperators, from->numCols * sizeof(Oid));
270  COPY_POINTER_FIELD(collations, from->numCols * sizeof(Oid));
271  COPY_POINTER_FIELD(nullsFirst, from->numCols * sizeof(bool));
272 
273  return newnode;
274 }
unsigned int Oid
Definition: postgres_ext.h:31
#define COPY_POINTER_FIELD(fldname, sz)
Definition: copyfuncs.c:57
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
static void CopyPlanFields(const Plan *from, Plan *newnode)
Definition: copyfuncs.c:115
#define makeNode(_type_)
Definition: nodes.h:557
int16 AttrNumber
Definition: attnum.h:21
static MergeJoin* _copyMergeJoin ( const MergeJoin from)
static

Definition at line 851 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_POINTER_FIELD, COPY_SCALAR_FIELD, CopyJoinFields(), list_length(), makeNode, and MergeJoin::mergeclauses.

Referenced by copyObjectImpl().

852 {
853  MergeJoin *newnode = makeNode(MergeJoin);
854  int numCols;
855 
856  /*
857  * copy node superclass fields
858  */
859  CopyJoinFields((const Join *) from, (Join *) newnode);
860 
861  /*
862  * copy remainder of node
863  */
864  COPY_SCALAR_FIELD(skip_mark_restore);
865  COPY_NODE_FIELD(mergeclauses);
866  numCols = list_length(from->mergeclauses);
867  if (numCols > 0)
868  {
869  COPY_POINTER_FIELD(mergeFamilies, numCols * sizeof(Oid));
870  COPY_POINTER_FIELD(mergeCollations, numCols * sizeof(Oid));
871  COPY_POINTER_FIELD(mergeStrategies, numCols * sizeof(int));
872  COPY_POINTER_FIELD(mergeNullsFirst, numCols * sizeof(bool));
873  }
874 
875  return newnode;
876 }
unsigned int Oid
Definition: postgres_ext.h:31
List * mergeclauses
Definition: plannodes.h:711
static void CopyJoinFields(const Join *from, Join *newnode)
Definition: copyfuncs.c:798
#define COPY_POINTER_FIELD(fldname, sz)
Definition: copyfuncs.c:57
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static int list_length(const List *l)
Definition: pg_list.h:89
static MinMaxExpr* _copyMinMaxExpr ( const MinMaxExpr from)
static

Definition at line 1862 of file copyfuncs.c.

References generate_unaccent_rules::args, COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

1863 {
1864  MinMaxExpr *newnode = makeNode(MinMaxExpr);
1865 
1866  COPY_SCALAR_FIELD(minmaxtype);
1867  COPY_SCALAR_FIELD(minmaxcollid);
1868  COPY_SCALAR_FIELD(inputcollid);
1869  COPY_SCALAR_FIELD(op);
1871  COPY_LOCATION_FIELD(location);
1872 
1873  return newnode;
1874 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:557
static ModifyTable* _copyModifyTable ( const ModifyTable from)
static

Definition at line 191 of file copyfuncs.c.

References COPY_BITMAPSET_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, CopyPlanFields(), and makeNode.

Referenced by copyObjectImpl().

192 {
193  ModifyTable *newnode = makeNode(ModifyTable);
194 
195  /*
196  * copy node superclass fields
197  */
198  CopyPlanFields((const Plan *) from, (Plan *) newnode);
199 
200  /*
201  * copy remainder of node
202  */
203  COPY_SCALAR_FIELD(operation);
204  COPY_SCALAR_FIELD(canSetTag);
205  COPY_SCALAR_FIELD(nominalRelation);
206  COPY_NODE_FIELD(partitioned_rels);
207  COPY_NODE_FIELD(resultRelations);
208  COPY_SCALAR_FIELD(resultRelIndex);
209  COPY_SCALAR_FIELD(rootResultRelIndex);
210  COPY_NODE_FIELD(plans);
211  COPY_NODE_FIELD(withCheckOptionLists);
212  COPY_NODE_FIELD(returningLists);
213  COPY_NODE_FIELD(fdwPrivLists);
214  COPY_BITMAPSET_FIELD(fdwDirectModifyPlans);
215  COPY_NODE_FIELD(rowMarks);
216  COPY_SCALAR_FIELD(epqParam);
217  COPY_SCALAR_FIELD(onConflictAction);
218  COPY_NODE_FIELD(arbiterIndexes);
219  COPY_NODE_FIELD(onConflictSet);
220  COPY_NODE_FIELD(onConflictWhere);
221  COPY_SCALAR_FIELD(exclRelRTI);
222  COPY_NODE_FIELD(exclRelTlist);
223 
224  return newnode;
225 }
#define COPY_BITMAPSET_FIELD(fldname)
Definition: copyfuncs.c:49
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
static void CopyPlanFields(const Plan *from, Plan *newnode)
Definition: copyfuncs.c:115
#define makeNode(_type_)
Definition: nodes.h:557
static MultiAssignRef* _copyMultiAssignRef ( const MultiAssignRef from)
static

Definition at line 2625 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObjectImpl().

2626 {
2628 
2629  COPY_NODE_FIELD(source);
2630  COPY_SCALAR_FIELD(colno);
2631  COPY_SCALAR_FIELD(ncolumns);
2632 
2633  return newnode;
2634 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:557
static NamedArgExpr* _copyNamedArgExpr ( const NamedArgExpr from)
static

Definition at line 1458 of file copyfuncs.c.

References arg, COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, makeNode, and name.

Referenced by copyObjectImpl().

1459 {
1460  NamedArgExpr *newnode = makeNode(NamedArgExpr);
1461 
1464  COPY_SCALAR_FIELD(argnumber);
1465  COPY_LOCATION_FIELD(location);
1466 
1467  return newnode;
1468 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45