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 = copyObject(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 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 ValuesScan_copyValuesScan (const ValuesScan *from)
 
static CteScan_copyCteScan (const CteScan *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 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 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 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 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 AlterDomainStmt_copyAlterDomainStmt (const AlterDomainStmt *from)
 
static GrantStmt_copyGrantStmt (const GrantStmt *from)
 
static FuncWithArgs_copyFuncWithArgs (const FuncWithArgs *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 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 PartitionSpec_copyPartitionSpec (const PartitionSpec *from)
 
static PartitionElem_copyPartitionElem (const PartitionElem *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 * copyObject (const void *from)
 

Macro Definition Documentation

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

Definition at line 4364 of file copyfuncs.c.

Referenced by _copyList().

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

Definition at line 45 of file copyfuncs.c.

Referenced by _copyA_ArrayExpr(), _copyA_Indirection(), _copyAccessPriv(), _copyAExpr(), _copyAgg(), _copyAggref(), _copyAIndices(), _copyAlias(), _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(), _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(), _copyFuncWithArgs(), _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(), _copyOnConflictClause(), _copyOnConflictExpr(), _copyOpExpr(), _copyPartitionBoundSpec(), _copyPartitionCmd(), _copyPartitionElem(), _copyPartitionRangeDatum(), _copyPartitionSpec(), _copyPlaceHolderInfo(), _copyPlaceHolderVar(), _copyPlannedStmt(), _copyPrepareStmt(), _copyQuery(), _copyRangeFunction(), _copyRangeSubselect(), _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(), _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:353
void * palloc(Size size)
Definition: mcxt.c:891

Definition at line 57 of file copyfuncs.c.

Referenced by _copyAgg(), _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(), _copyAlterTableCmd(), _copyAlterTableMoveAllStmt(), _copyAlterTableSpaceOptionsStmt(), _copyAlterTableStmt(), _copyAlterTSConfigurationStmt(), _copyAppendRelInfo(), _copyArrayCoerceExpr(), _copyArrayExpr(), _copyArrayRef(), _copyBitmapIndexScan(), _copyBooleanTest(), _copyBoolExpr(), _copyCaseExpr(), _copyCaseTestExpr(), _copyClusterStmt(), _copyCoalesceExpr(), _copyCoerceToDomain(), _copyCoerceToDomainValue(), _copyCoerceViaIO(), _copyCollateExpr(), _copyColumnDef(), _copyCommentStmt(), _copyCommonTableExpr(), _copyConst(), _copyConstraint(), _copyConstraintsSetStmt(), _copyConvertRowtypeExpr(), _copyCopyStmt(), _copyCreateAmStmt(), _copyCreateCastStmt(), _copyCreateConversionStmt(), _copyCreateExtensionStmt(), _copyCreateFunctionStmt(), _copyCreateOpClassItem(), _copyCreateOpClassStmt(), _copyCreatePLangStmt(), _copyCreatePolicyStmt(), _copyCreatePublicationStmt(), _copyCreateRoleStmt(), _copyCreateSchemaStmt(), _copyCreateSeqStmt(), _copyCreateTableAsStmt(), _copyCreateTransformStmt(), _copyCreateTrigStmt(), _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(), _copyGrantRoleStmt(), _copyGrantStmt(), _copyGroup(), _copyGroupingFunc(), _copyGroupingSet(), _copyHash(), _copyImportForeignSchemaStmt(), _copyIndexElem(), _copyIndexOnlyScan(), _copyIndexScan(), _copyIndexStmt(), _copyInferenceElem(), _copyIntoClause(), _copyJoinExpr(), _copyLockingClause(), _copyLockRows(), _copyLockStmt(), _copyMergeAppend(), _copyMinMaxExpr(), _copyModifyTable(), _copyMultiAssignRef(), _copyNamedArgExpr(), _copyNestLoopParam(), _copyNullIfExpr(), _copyNullTest(), _copyOnConflictClause(), _copyOnConflictExpr(), _copyOpExpr(), _copyParam(), _copyParamRef(), _copyPartitionBoundSpec(), _copyPartitionRangeDatum(), _copyPathKey(), _copyPlaceHolderInfo(), _copyPlaceHolderVar(), _copyPlanInvalItem(), _copyPlannedStmt(), _copyPlanRowMark(), _copyQuery(), _copyRangeFunction(), _copyRangeSubselect(), _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(), _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(), _copyNotifyStmt(), _copyPartitionElem(), _copyPartitionSpec(), _copyPrepareStmt(), _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 2469 of file copyfuncs.c.

References COPY_LOCATION_FIELD, COPY_NODE_FIELD, and makeNode.

Referenced by copyObject().

2470 {
2471  A_ArrayExpr *newnode = makeNode(A_ArrayExpr);
2472 
2473  COPY_NODE_FIELD(elements);
2474  COPY_LOCATION_FIELD(location);
2475 
2476  return newnode;
2477 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:556
static A_Indirection* _copyA_Indirection ( const A_Indirection from)
static

Definition at line 2458 of file copyfuncs.c.

References arg, COPY_NODE_FIELD, and makeNode.

Referenced by copyObject().

2459 {
2460  A_Indirection *newnode = makeNode(A_Indirection);
2461 
2463  COPY_NODE_FIELD(indirection);
2464 
2465  return newnode;
2466 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
void * arg
static AccessPriv* _copyAccessPriv ( const AccessPriv from)
static

Definition at line 2969 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

2970 {
2971  AccessPriv *newnode = makeNode(AccessPriv);
2972 
2973  COPY_STRING_FIELD(priv_name);
2974  COPY_NODE_FIELD(cols);
2975 
2976  return newnode;
2977 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
static A_Const* _copyAConst ( const A_Const from)
static

Definition at line 2388 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 copyObject().

2389 {
2390  A_Const *newnode = makeNode(A_Const);
2391 
2392  /* This part must duplicate _copyValue */
2393  COPY_SCALAR_FIELD(val.type);
2394  switch (from->val.type)
2395  {
2396  case T_Integer:
2397  COPY_SCALAR_FIELD(val.val.ival);
2398  break;
2399  case T_Float:
2400  case T_String:
2401  case T_BitString:
2402  COPY_STRING_FIELD(val.val.str);
2403  break;
2404  case T_Null:
2405  /* nothing to do */
2406  break;
2407  default:
2408  elog(ERROR, "unrecognized node type: %d",
2409  (int) from->val.type);
2410  break;
2411  }
2412 
2413  COPY_LOCATION_FIELD(location);
2414 
2415  return newnode;
2416 }
#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:556
Definition: nodes.h:290
Definition: nodes.h:287
#define elog
Definition: elog.h:219
Value val
Definition: parsenodes.h:279
long val
Definition: informix.c:689
NodeTag type
Definition: value.h:44
static A_Expr* _copyAExpr ( const A_Expr from)
static

Definition at line 2352 of file copyfuncs.c.

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

Referenced by copyObject().

2353 {
2354  A_Expr *newnode = makeNode(A_Expr);
2355 
2356  COPY_SCALAR_FIELD(kind);
2358  COPY_NODE_FIELD(lexpr);
2359  COPY_NODE_FIELD(rexpr);
2360  COPY_LOCATION_FIELD(location);
2361 
2362  return newnode;
2363 }
#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:556
const char * name
Definition: encode.c:521
static Agg* _copyAgg ( const Agg from)
static

Definition at line 883 of file copyfuncs.c.

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

Referenced by copyObject().

884 {
885  Agg *newnode = makeNode(Agg);
886 
887  CopyPlanFields((const Plan *) from, (Plan *) newnode);
888 
889  COPY_SCALAR_FIELD(aggstrategy);
890  COPY_SCALAR_FIELD(aggsplit);
891  COPY_SCALAR_FIELD(numCols);
892  if (from->numCols > 0)
893  {
894  COPY_POINTER_FIELD(grpColIdx, from->numCols * sizeof(AttrNumber));
895  COPY_POINTER_FIELD(grpOperators, from->numCols * sizeof(Oid));
896  }
897  COPY_SCALAR_FIELD(numGroups);
898  COPY_BITMAPSET_FIELD(aggParams);
899  COPY_NODE_FIELD(groupingSets);
900  COPY_NODE_FIELD(chain);
901 
902  return newnode;
903 }
#define COPY_BITMAPSET_FIELD(fldname)
Definition: copyfuncs.c:49
int numCols
Definition: plannodes.h:735
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:113
#define makeNode(_type_)
Definition: nodes.h:556
Definition: plannodes.h:730
int16 AttrNumber
Definition: attnum.h:21
static Aggref* _copyAggref ( const Aggref from)
static

Definition at line 1248 of file copyfuncs.c.

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

Referenced by copyObject().

1249 {
1250  Aggref *newnode = makeNode(Aggref);
1251 
1252  COPY_SCALAR_FIELD(aggfnoid);
1253  COPY_SCALAR_FIELD(aggtype);
1254  COPY_SCALAR_FIELD(aggcollid);
1255  COPY_SCALAR_FIELD(inputcollid);
1256  COPY_SCALAR_FIELD(aggtranstype);
1257  COPY_NODE_FIELD(aggargtypes);
1258  COPY_NODE_FIELD(aggdirectargs);
1260  COPY_NODE_FIELD(aggorder);
1261  COPY_NODE_FIELD(aggdistinct);
1262  COPY_NODE_FIELD(aggfilter);
1263  COPY_SCALAR_FIELD(aggstar);
1264  COPY_SCALAR_FIELD(aggvariadic);
1265  COPY_SCALAR_FIELD(aggkind);
1266  COPY_SCALAR_FIELD(agglevelsup);
1267  COPY_SCALAR_FIELD(aggsplit);
1268  COPY_LOCATION_FIELD(location);
1269 
1270  return newnode;
1271 }
#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:556
static A_Indices* _copyAIndices ( const A_Indices from)
static

Definition at line 2446 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

2447 {
2448  A_Indices *newnode = makeNode(A_Indices);
2449 
2450  COPY_SCALAR_FIELD(is_slice);
2451  COPY_NODE_FIELD(lidx);
2452  COPY_NODE_FIELD(uidx);
2453 
2454  return newnode;
2455 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static Alias* _copyAlias ( const Alias from)
static

Definition at line 1112 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

1113 {
1114  Alias *newnode = makeNode(Alias);
1115 
1116  COPY_STRING_FIELD(aliasname);
1117  COPY_NODE_FIELD(colnames);
1118 
1119  return newnode;
1120 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
static AlterDatabaseSetStmt* _copyAlterDatabaseSetStmt ( const AlterDatabaseSetStmt from)
static

Definition at line 3553 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, dbname, and makeNode.

Referenced by copyObject().

3554 {
3556 
3558  COPY_NODE_FIELD(setstmt);
3559 
3560  return newnode;
3561 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
char * dbname
Definition: streamutil.c:41
static AlterDatabaseStmt* _copyAlterDatabaseStmt ( const AlterDatabaseStmt from)
static

Definition at line 3542 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, dbname, and makeNode.

Referenced by copyObject().

3543 {
3545 
3548 
3549  return newnode;
3550 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
char * dbname
Definition: streamutil.c:41
static AlterDefaultPrivilegesStmt* _copyAlterDefaultPrivilegesStmt ( const AlterDefaultPrivilegesStmt from)
static

Definition at line 2995 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObject().

2996 {
2998 
3000  COPY_NODE_FIELD(action);
3001 
3002  return newnode;
3003 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static AlterDomainStmt* _copyAlterDomainStmt ( const AlterDomainStmt from)
static

Definition at line 2926 of file copyfuncs.c.

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

Referenced by copyObject().

2927 {
2929 
2930  COPY_SCALAR_FIELD(subtype);
2931  COPY_NODE_FIELD(typeName);
2933  COPY_NODE_FIELD(def);
2934  COPY_SCALAR_FIELD(behavior);
2935  COPY_SCALAR_FIELD(missing_ok);
2936 
2937  return newnode;
2938 }
#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:556
const char * name
Definition: encode.c:521
static AlterEnumStmt* _copyAlterEnumStmt ( const AlterEnumStmt from)
static

Definition at line 3423 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3424 {
3425  AlterEnumStmt *newnode = makeNode(AlterEnumStmt);
3426 
3427  COPY_NODE_FIELD(typeName);
3428  COPY_STRING_FIELD(oldVal);
3429  COPY_STRING_FIELD(newVal);
3430  COPY_STRING_FIELD(newValNeighbor);
3431  COPY_SCALAR_FIELD(newValIsAfter);
3432  COPY_SCALAR_FIELD(skipIfNewValExists);
3433 
3434  return newnode;
3435 }
#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:556
static AlterEventTrigStmt* _copyAlterEventTrigStmt ( const AlterEventTrigStmt from)
static

Definition at line 3967 of file copyfuncs.c.

References COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3968 {
3970 
3971  COPY_STRING_FIELD(trigname);
3972  COPY_SCALAR_FIELD(tgenabled);
3973 
3974  return newnode;
3975 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
static AlterExtensionContentsStmt* _copyAlterExtensionContentsStmt ( const AlterExtensionContentsStmt from)
static

Definition at line 3776 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3777 {
3779 
3780  COPY_STRING_FIELD(extname);
3781  COPY_SCALAR_FIELD(action);
3782  COPY_SCALAR_FIELD(objtype);
3783  COPY_NODE_FIELD(objname);
3784  COPY_NODE_FIELD(objargs);
3785 
3786  return newnode;
3787 }
#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:556
static AlterExtensionStmt* _copyAlterExtensionStmt ( const AlterExtensionStmt from)
static

Definition at line 3765 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3766 {
3768 
3769  COPY_STRING_FIELD(extname);
3771 
3772  return newnode;
3773 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
static AlterFdwStmt* _copyAlterFdwStmt ( const AlterFdwStmt from)
static

Definition at line 3802 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3803 {
3804  AlterFdwStmt *newnode = makeNode(AlterFdwStmt);
3805 
3806  COPY_STRING_FIELD(fdwname);
3807  COPY_NODE_FIELD(func_options);
3809 
3810  return newnode;
3811 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
static AlterForeignServerStmt* _copyAlterForeignServerStmt ( const AlterForeignServerStmt from)
static

Definition at line 3828 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3829 {
3831 
3832  COPY_STRING_FIELD(servername);
3833  COPY_STRING_FIELD(version);
3835  COPY_SCALAR_FIELD(has_version);
3836 
3837  return newnode;
3838 }
#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:556
static AlterFunctionStmt* _copyAlterFunctionStmt ( const AlterFunctionStmt from)
static

Definition at line 3237 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObject().

3238 {
3240 
3241  COPY_NODE_FIELD(func);
3242  COPY_NODE_FIELD(actions);
3243 
3244  return newnode;
3245 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static AlternativeSubPlan* _copyAlternativeSubPlan ( const AlternativeSubPlan from)
static

Definition at line 1512 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObject().

1513 {
1515 
1516  COPY_NODE_FIELD(subplans);
1517 
1518  return newnode;
1519 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static AlterObjectDependsStmt* _copyAlterObjectDependsStmt ( const AlterObjectDependsStmt from)
static

Definition at line 3276 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

3277 {
3279 
3280  COPY_SCALAR_FIELD(objectType);
3281  COPY_NODE_FIELD(relation);
3282  COPY_NODE_FIELD(objname);
3283  COPY_NODE_FIELD(objargs);
3284  COPY_NODE_FIELD(extname);
3285 
3286  return newnode;
3287 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static AlterObjectSchemaStmt* _copyAlterObjectSchemaStmt ( const AlterObjectSchemaStmt from)
static

Definition at line 3290 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3291 {
3293 
3294  COPY_SCALAR_FIELD(objectType);
3295  COPY_NODE_FIELD(relation);
3296  COPY_NODE_FIELD(object);
3297  COPY_NODE_FIELD(objarg);
3298  COPY_STRING_FIELD(newschema);
3299  COPY_SCALAR_FIELD(missing_ok);
3300 
3301  return newnode;
3302 }
#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:556
static AlterOperatorStmt* _copyAlterOperatorStmt ( const AlterOperatorStmt from)
static

Definition at line 3319 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObject().

3320 {
3322 
3323  COPY_NODE_FIELD(opername);
3324  COPY_NODE_FIELD(operargs);
3326 
3327  return newnode;
3328 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static AlterOpFamilyStmt* _copyAlterOpFamilyStmt ( const AlterOpFamilyStmt from)
static

Definition at line 3518 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3519 {
3521 
3522  COPY_NODE_FIELD(opfamilyname);
3523  COPY_STRING_FIELD(amname);
3524  COPY_SCALAR_FIELD(isDrop);
3525  COPY_NODE_FIELD(items);
3526 
3527  return newnode;
3528 }
#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:556
static AlterOwnerStmt* _copyAlterOwnerStmt ( const AlterOwnerStmt from)
static

Definition at line 3305 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

3306 {
3308 
3309  COPY_SCALAR_FIELD(objectType);
3310  COPY_NODE_FIELD(relation);
3311  COPY_NODE_FIELD(object);
3312  COPY_NODE_FIELD(objarg);
3313  COPY_NODE_FIELD(newowner);
3314 
3315  return newnode;
3316 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static AlterPolicyStmt* _copyAlterPolicyStmt ( const AlterPolicyStmt from)
static

Definition at line 4215 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

4216 {
4218 
4219  COPY_STRING_FIELD(policy_name);
4220  COPY_NODE_FIELD(table);
4221  COPY_NODE_FIELD(roles);
4222  COPY_NODE_FIELD(qual);
4223  COPY_NODE_FIELD(with_check);
4224 
4225  return newnode;
4226 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
static AlterPublicationStmt* _copyAlterPublicationStmt ( const AlterPublicationStmt from)
static

Definition at line 4305 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

4306 {
4308 
4309  COPY_STRING_FIELD(pubname);
4311  COPY_NODE_FIELD(tables);
4312  COPY_SCALAR_FIELD(for_all_tables);
4313  COPY_SCALAR_FIELD(tableAction);
4314 
4315  return newnode;
4316 }
#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:556
static AlterRoleSetStmt* _copyAlterRoleSetStmt ( const AlterRoleSetStmt from)
static

Definition at line 4017 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

4018 {
4020 
4021  COPY_NODE_FIELD(role);
4022  COPY_STRING_FIELD(database);
4023  COPY_NODE_FIELD(setstmt);
4024 
4025  return newnode;
4026 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
static AlterRoleStmt* _copyAlterRoleStmt ( const AlterRoleStmt from)
static

Definition at line 4005 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

4006 {
4007  AlterRoleStmt *newnode = makeNode(AlterRoleStmt);
4008 
4009  COPY_NODE_FIELD(role);
4011  COPY_SCALAR_FIELD(action);
4012 
4013  return newnode;
4014 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static AlterSeqStmt* _copyAlterSeqStmt ( const AlterSeqStmt from)
static

Definition at line 3658 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

3659 {
3660  AlterSeqStmt *newnode = makeNode(AlterSeqStmt);
3661 
3662  COPY_NODE_FIELD(sequence);
3664  COPY_SCALAR_FIELD(missing_ok);
3665 
3666  return newnode;
3667 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static AlterSubscriptionStmt* _copyAlterSubscriptionStmt ( const AlterSubscriptionStmt from)
static

Definition at line 4332 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

4333 {
4335 
4336  COPY_STRING_FIELD(subname);
4338 
4339  return newnode;
4340 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
static AlterSystemStmt* _copyAlterSystemStmt ( const AlterSystemStmt from)
static

Definition at line 3635 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObject().

3636 {
3638 
3639  COPY_NODE_FIELD(setstmt);
3640 
3641  return newnode;
3642 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static AlterTableCmd* _copyAlterTableCmd ( const AlterTableCmd from)
static

Definition at line 2911 of file copyfuncs.c.

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

Referenced by copyObject().

2912 {
2913  AlterTableCmd *newnode = makeNode(AlterTableCmd);
2914 
2915  COPY_SCALAR_FIELD(subtype);
2917  COPY_NODE_FIELD(newowner);
2918  COPY_NODE_FIELD(def);
2919  COPY_SCALAR_FIELD(behavior);
2920  COPY_SCALAR_FIELD(missing_ok);
2921 
2922  return newnode;
2923 }
#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:556
const char * name
Definition: encode.c:521
static AlterTableMoveAllStmt* _copyAlterTableMoveAllStmt ( const AlterTableMoveAllStmt from)
static

Definition at line 3739 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3740 {
3742 
3743  COPY_STRING_FIELD(orig_tablespacename);
3744  COPY_SCALAR_FIELD(objtype);
3745  COPY_NODE_FIELD(roles);
3746  COPY_STRING_FIELD(new_tablespacename);
3747  COPY_SCALAR_FIELD(nowait);
3748 
3749  return newnode;
3750 }
#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:556
static AlterTableSpaceOptionsStmt* _copyAlterTableSpaceOptionsStmt ( const AlterTableSpaceOptionsStmt from)
static

Definition at line 3727 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3728 {
3730 
3731  COPY_STRING_FIELD(tablespacename);
3733  COPY_SCALAR_FIELD(isReset);
3734 
3735  return newnode;
3736 }
#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:556
static AlterTableStmt* _copyAlterTableStmt ( const AlterTableStmt from)
static

Definition at line 2898 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

2899 {
2901 
2902  COPY_NODE_FIELD(relation);
2903  COPY_NODE_FIELD(cmds);
2904  COPY_SCALAR_FIELD(relkind);
2905  COPY_SCALAR_FIELD(missing_ok);
2906 
2907  return newnode;
2908 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static AlterTSConfigurationStmt* _copyAlterTSConfigurationStmt ( const AlterTSConfigurationStmt from)
static

Definition at line 4183 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

4184 {
4186 
4187  COPY_SCALAR_FIELD(kind);
4188  COPY_NODE_FIELD(cfgname);
4189  COPY_NODE_FIELD(tokentype);
4190  COPY_NODE_FIELD(dicts);
4191  COPY_SCALAR_FIELD(override);
4192  COPY_SCALAR_FIELD(replace);
4193  COPY_SCALAR_FIELD(missing_ok);
4194 
4195  return newnode;
4196 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static AlterTSDictionaryStmt* _copyAlterTSDictionaryStmt ( const AlterTSDictionaryStmt from)
static

Definition at line 4172 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObject().

4173 {
4175 
4176  COPY_NODE_FIELD(dictname);
4178 
4179  return newnode;
4180 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static AlterUserMappingStmt* _copyAlterUserMappingStmt ( const AlterUserMappingStmt from)
static

Definition at line 3853 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, makeNode, and user.

Referenced by copyObject().

3854 {
3856 
3858  COPY_STRING_FIELD(servername);
3860 
3861  return newnode;
3862 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
static char * user
Definition: pg_regress.c:90
static Append* _copyAppend ( const Append from)
static

Definition at line 226 of file copyfuncs.c.

References COPY_NODE_FIELD, CopyPlanFields(), and makeNode.

Referenced by copyObject().

227 {
228  Append *newnode = makeNode(Append);
229 
230  /*
231  * copy node superclass fields
232  */
233  CopyPlanFields((const Plan *) from, (Plan *) newnode);
234 
235  /*
236  * copy remainder of node
237  */
238  COPY_NODE_FIELD(appendplans);
239 
240  return newnode;
241 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
static void CopyPlanFields(const Plan *from, Plan *newnode)
Definition: copyfuncs.c:113
#define makeNode(_type_)
Definition: nodes.h:556
static AppendRelInfo* _copyAppendRelInfo ( const AppendRelInfo from)
static

Definition at line 2120 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

2121 {
2122  AppendRelInfo *newnode = makeNode(AppendRelInfo);
2123 
2124  COPY_SCALAR_FIELD(parent_relid);
2125  COPY_SCALAR_FIELD(child_relid);
2126  COPY_SCALAR_FIELD(parent_reltype);
2127  COPY_SCALAR_FIELD(child_reltype);
2128  COPY_NODE_FIELD(translated_vars);
2129  COPY_SCALAR_FIELD(parent_reloid);
2130 
2131  return newnode;
2132 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static ArrayCoerceExpr* _copyArrayCoerceExpr ( const ArrayCoerceExpr from)
static

Definition at line 1593 of file copyfuncs.c.

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

Referenced by copyObject().

1594 {
1596 
1598  COPY_SCALAR_FIELD(elemfuncid);
1599  COPY_SCALAR_FIELD(resulttype);
1600  COPY_SCALAR_FIELD(resulttypmod);
1601  COPY_SCALAR_FIELD(resultcollid);
1602  COPY_SCALAR_FIELD(isExplicit);
1603  COPY_SCALAR_FIELD(coerceformat);
1604  COPY_LOCATION_FIELD(location);
1605 
1606  return newnode;
1607 }
#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:556
void * arg
static ArrayExpr* _copyArrayExpr ( const ArrayExpr from)
static

Definition at line 1692 of file copyfuncs.c.

References COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

1693 {
1694  ArrayExpr *newnode = makeNode(ArrayExpr);
1695 
1696  COPY_SCALAR_FIELD(array_typeid);
1697  COPY_SCALAR_FIELD(array_collid);
1698  COPY_SCALAR_FIELD(element_typeid);
1699  COPY_NODE_FIELD(elements);
1700  COPY_SCALAR_FIELD(multidims);
1701  COPY_LOCATION_FIELD(location);
1702 
1703  return newnode;
1704 }
#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:556
static ArrayRef* _copyArrayRef ( const ArrayRef from)
static

Definition at line 1316 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

1317 {
1318  ArrayRef *newnode = makeNode(ArrayRef);
1319 
1320  COPY_SCALAR_FIELD(refarraytype);
1321  COPY_SCALAR_FIELD(refelemtype);
1322  COPY_SCALAR_FIELD(reftypmod);
1323  COPY_SCALAR_FIELD(refcollid);
1324  COPY_NODE_FIELD(refupperindexpr);
1325  COPY_NODE_FIELD(reflowerindexpr);
1326  COPY_NODE_FIELD(refexpr);
1327  COPY_NODE_FIELD(refassgnexpr);
1328 
1329  return newnode;
1330 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static A_Star* _copyAStar ( const A_Star from)
static

Definition at line 2438 of file copyfuncs.c.

References makeNode.

Referenced by copyObject().

2439 {
2440  A_Star *newnode = makeNode(A_Star);
2441 
2442  return newnode;
2443 }
#define makeNode(_type_)
Definition: nodes.h:556
static BitmapAnd* _copyBitmapAnd ( const BitmapAnd from)
static

Definition at line 301 of file copyfuncs.c.

References COPY_NODE_FIELD, CopyPlanFields(), and makeNode.

Referenced by copyObject().

302 {
303  BitmapAnd *newnode = makeNode(BitmapAnd);
304 
305  /*
306  * copy node superclass fields
307  */
308  CopyPlanFields((const Plan *) from, (Plan *) newnode);
309 
310  /*
311  * copy remainder of node
312  */
313  COPY_NODE_FIELD(bitmapplans);
314 
315  return newnode;
316 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
static void CopyPlanFields(const Plan *from, Plan *newnode)
Definition: copyfuncs.c:113
#define makeNode(_type_)
Definition: nodes.h:556
static BitmapHeapScan* _copyBitmapHeapScan ( const BitmapHeapScan from)
static

Definition at line 509 of file copyfuncs.c.

References COPY_NODE_FIELD, CopyScanFields(), and makeNode.

Referenced by copyObject().

510 {
512 
513  /*
514  * copy node superclass fields
515  */
516  CopyScanFields((const Scan *) from, (Scan *) newnode);
517 
518  /*
519  * copy remainder of node
520  */
521  COPY_NODE_FIELD(bitmapqualorig);
522 
523  return newnode;
524 }
static void CopyScanFields(const Scan *from, Scan *newnode)
Definition: copyfuncs.c:370
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static BitmapIndexScan* _copyBitmapIndexScan ( const BitmapIndexScan from)
static

Definition at line 486 of file copyfuncs.c.

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

Referenced by copyObject().

487 {
489 
490  /*
491  * copy node superclass fields
492  */
493  CopyScanFields((const Scan *) from, (Scan *) newnode);
494 
495  /*
496  * copy remainder of node
497  */
498  COPY_SCALAR_FIELD(indexid);
499  COPY_NODE_FIELD(indexqual);
500  COPY_NODE_FIELD(indexqualorig);
501 
502  return newnode;
503 }
static void CopyScanFields(const Scan *from, Scan *newnode)
Definition: copyfuncs.c:370
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static BitmapOr* _copyBitmapOr ( const BitmapOr from)
static

Definition at line 322 of file copyfuncs.c.

References COPY_NODE_FIELD, CopyPlanFields(), and makeNode.

Referenced by copyObject().

323 {
324  BitmapOr *newnode = makeNode(BitmapOr);
325 
326  /*
327  * copy node superclass fields
328  */
329  CopyPlanFields((const Plan *) from, (Plan *) newnode);
330 
331  /*
332  * copy remainder of node
333  */
334  COPY_NODE_FIELD(bitmapplans);
335 
336  return newnode;
337 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
static void CopyPlanFields(const Plan *from, Plan *newnode)
Definition: copyfuncs.c:113
#define makeNode(_type_)
Definition: nodes.h:556
static BooleanTest* _copyBooleanTest ( const BooleanTest from)
static

Definition at line 1832 of file copyfuncs.c.

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

Referenced by copyObject().

1833 {
1834  BooleanTest *newnode = makeNode(BooleanTest);
1835 
1837  COPY_SCALAR_FIELD(booltesttype);
1838  COPY_LOCATION_FIELD(location);
1839 
1840  return newnode;
1841 }
#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:556
void * arg
static BoolExpr* _copyBoolExpr ( const BoolExpr from)
static

Definition at line 1451 of file copyfuncs.c.

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

Referenced by copyObject().

1452 {
1453  BoolExpr *newnode = makeNode(BoolExpr);
1454 
1457  COPY_LOCATION_FIELD(location);
1458 
1459  return newnode;
1460 }
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:556
static CaseExpr* _copyCaseExpr ( const CaseExpr from)
static

Definition at line 1644 of file copyfuncs.c.

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

Referenced by copyObject().

1645 {
1646  CaseExpr *newnode = makeNode(CaseExpr);
1647 
1648  COPY_SCALAR_FIELD(casetype);
1649  COPY_SCALAR_FIELD(casecollid);
1652  COPY_NODE_FIELD(defresult);
1653  COPY_LOCATION_FIELD(location);
1654 
1655  return newnode;
1656 }
#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:556
void * arg
static CaseTestExpr* _copyCaseTestExpr ( const CaseTestExpr from)
static

Definition at line 1677 of file copyfuncs.c.

References COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

1678 {
1679  CaseTestExpr *newnode = makeNode(CaseTestExpr);
1680 
1681  COPY_SCALAR_FIELD(typeId);
1682  COPY_SCALAR_FIELD(typeMod);
1683  COPY_SCALAR_FIELD(collation);
1684 
1685  return newnode;
1686 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define makeNode(_type_)
Definition: nodes.h:556
static CaseWhen* _copyCaseWhen ( const CaseWhen from)
static

Definition at line 1662 of file copyfuncs.c.

References COPY_LOCATION_FIELD, COPY_NODE_FIELD, and makeNode.

Referenced by copyObject().

1663 {
1664  CaseWhen *newnode = makeNode(CaseWhen);
1665 
1666  COPY_NODE_FIELD(expr);
1667  COPY_NODE_FIELD(result);
1668  COPY_LOCATION_FIELD(location);
1669 
1670  return newnode;
1671 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:556
static ClosePortalStmt* _copyClosePortalStmt ( const ClosePortalStmt from)
static

Definition at line 3018 of file copyfuncs.c.

References COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3019 {
3021 
3022  COPY_STRING_FIELD(portalname);
3023 
3024  return newnode;
3025 }
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
static ClusterStmt* _copyClusterStmt ( const ClusterStmt from)
static

Definition at line 3028 of file copyfuncs.c.

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

Referenced by copyObject().

3029 {
3030  ClusterStmt *newnode = makeNode(ClusterStmt);
3031 
3032  COPY_NODE_FIELD(relation);
3033  COPY_STRING_FIELD(indexname);
3035 
3036  return newnode;
3037 }
#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:87
#define makeNode(_type_)
Definition: nodes.h:556
static CoalesceExpr* _copyCoalesceExpr ( const CoalesceExpr from)
static

Definition at line 1745 of file copyfuncs.c.

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

Referenced by copyObject().

1746 {
1747  CoalesceExpr *newnode = makeNode(CoalesceExpr);
1748 
1749  COPY_SCALAR_FIELD(coalescetype);
1750  COPY_SCALAR_FIELD(coalescecollid);
1752  COPY_LOCATION_FIELD(location);
1753 
1754  return newnode;
1755 }
#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:556
static CoerceToDomain* _copyCoerceToDomain ( const CoerceToDomain from)
static

Definition at line 1847 of file copyfuncs.c.

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

Referenced by copyObject().

1848 {
1850 
1852  COPY_SCALAR_FIELD(resulttype);
1853  COPY_SCALAR_FIELD(resulttypmod);
1854  COPY_SCALAR_FIELD(resultcollid);
1855  COPY_SCALAR_FIELD(coercionformat);
1856  COPY_LOCATION_FIELD(location);
1857 
1858  return newnode;
1859 }
#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:556
void * arg
static CoerceToDomainValue* _copyCoerceToDomainValue ( const CoerceToDomainValue from)
static

Definition at line 1865 of file copyfuncs.c.

References COPY_LOCATION_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

1866 {
1868 
1869  COPY_SCALAR_FIELD(typeId);
1870  COPY_SCALAR_FIELD(typeMod);
1871  COPY_SCALAR_FIELD(collation);
1872  COPY_LOCATION_FIELD(location);
1873 
1874  return newnode;
1875 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:556
static CoerceViaIO* _copyCoerceViaIO ( const CoerceViaIO from)
static

Definition at line 1576 of file copyfuncs.c.

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

Referenced by copyObject().

1577 {
1578  CoerceViaIO *newnode = makeNode(CoerceViaIO);
1579 
1581  COPY_SCALAR_FIELD(resulttype);
1582  COPY_SCALAR_FIELD(resultcollid);
1583  COPY_SCALAR_FIELD(coerceformat);
1584  COPY_LOCATION_FIELD(location);
1585 
1586  return newnode;
1587 }
#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:556
void * arg
static CollateClause* _copyCollateClause ( const CollateClause from)
static

Definition at line 2606 of file copyfuncs.c.

References arg, COPY_LOCATION_FIELD, COPY_NODE_FIELD, and makeNode.

Referenced by copyObject().

2607 {
2608  CollateClause *newnode = makeNode(CollateClause);
2609 
2611  COPY_NODE_FIELD(collname);
2612  COPY_LOCATION_FIELD(location);
2613 
2614  return newnode;
2615 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:556
void * arg
static CollateExpr* _copyCollateExpr ( const CollateExpr from)
static

Definition at line 1629 of file copyfuncs.c.

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

Referenced by copyObject().

1630 {
1631  CollateExpr *newnode = makeNode(CollateExpr);
1632 
1634  COPY_SCALAR_FIELD(collOid);
1635  COPY_LOCATION_FIELD(location);
1636 
1637  return newnode;
1638 }
#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:556
void * arg
static ColumnDef* _copyColumnDef ( const ColumnDef from)
static

Definition at line 2634 of file copyfuncs.c.

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

Referenced by copyObject().

2635 {
2636  ColumnDef *newnode = makeNode(ColumnDef);
2637 
2638  COPY_STRING_FIELD(colname);
2639  COPY_NODE_FIELD(typeName);
2640  COPY_SCALAR_FIELD(inhcount);
2641  COPY_SCALAR_FIELD(is_local);
2642  COPY_SCALAR_FIELD(is_not_null);
2643  COPY_SCALAR_FIELD(is_from_type);
2644  COPY_SCALAR_FIELD(storage);
2645  COPY_NODE_FIELD(raw_default);
2646  COPY_NODE_FIELD(cooked_default);
2647  COPY_NODE_FIELD(collClause);
2648  COPY_SCALAR_FIELD(collOid);
2649  COPY_NODE_FIELD(constraints);
2650  COPY_NODE_FIELD(fdwoptions);
2651  COPY_LOCATION_FIELD(location);
2652 
2653  return newnode;
2654 }
#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:556
static ColumnRef* _copyColumnRef ( const ColumnRef from)
static

Definition at line 2366 of file copyfuncs.c.

References COPY_LOCATION_FIELD, COPY_NODE_FIELD, and makeNode.

Referenced by copyObject().

2367 {
2368  ColumnRef *newnode = makeNode(ColumnRef);
2369 
2370  COPY_NODE_FIELD(fields);
2371  COPY_LOCATION_FIELD(location);
2372 
2373  return newnode;
2374 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_LOCATION_FIELD(fldname)
Definition: copyfuncs.c:65
#define makeNode(_type_)
Definition: nodes.h:556
static CommentStmt* _copyCommentStmt ( const CommentStmt from)
static

Definition at line 3141 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3142 {
3143  CommentStmt *newnode = makeNode(CommentStmt);
3144 
3145  COPY_SCALAR_FIELD(objtype);
3146  COPY_NODE_FIELD(objname);
3147  COPY_NODE_FIELD(objargs);
3148  COPY_STRING_FIELD(comment);
3149 
3150  return newnode;
3151 }
#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:556
static CommonTableExpr* _copyCommonTableExpr ( const CommonTableExpr from)
static

Definition at line 2333 of file copyfuncs.c.

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

Referenced by copyObject().

2334 {
2336 
2337  COPY_STRING_FIELD(ctename);
2338  COPY_NODE_FIELD(aliascolnames);
2339  COPY_NODE_FIELD(ctequery);
2340  COPY_LOCATION_FIELD(location);
2341  COPY_SCALAR_FIELD(cterecursive);
2342  COPY_SCALAR_FIELD(cterefcount);
2343  COPY_NODE_FIELD(ctecolnames);
2344  COPY_NODE_FIELD(ctecoltypes);
2345  COPY_NODE_FIELD(ctecoltypmods);
2346  COPY_NODE_FIELD(ctecolcollations);
2347 
2348  return newnode;
2349 }
#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:556
static CompositeTypeStmt* _copyCompositeTypeStmt ( const CompositeTypeStmt from)
static

Definition at line 3390 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObject().

3391 {
3393 
3394  COPY_NODE_FIELD(typevar);
3395  COPY_NODE_FIELD(coldeflist);
3396 
3397  return newnode;
3398 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static Const* _copyConst ( const Const from)
static

Definition at line 1192 of file copyfuncs.c.

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

Referenced by copyObject().

1193 {
1194  Const *newnode = makeNode(Const);
1195 
1196  COPY_SCALAR_FIELD(consttype);
1197  COPY_SCALAR_FIELD(consttypmod);
1198  COPY_SCALAR_FIELD(constcollid);
1199  COPY_SCALAR_FIELD(constlen);
1200 
1201  if (from->constbyval || from->constisnull)
1202  {
1203  /*
1204  * passed by value so just copy the datum. Also, don't try to copy
1205  * struct when value is null!
1206  */
1207  newnode->constvalue = from->constvalue;
1208  }
1209  else
1210  {
1211  /*
1212  * passed by reference. We need a palloc'd copy.
1213  */
1214  newnode->constvalue = datumCopy(from->constvalue,
1215  from->constbyval,
1216  from->constlen);
1217  }
1218 
1219  COPY_SCALAR_FIELD(constisnull);
1220  COPY_SCALAR_FIELD(constbyval);
1221  COPY_LOCATION_FIELD(location);
1222 
1223  return newnode;
1224 }
Datum constvalue
Definition: primnodes.h:174
bool constbyval
Definition: primnodes.h:177
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
int constlen
Definition: primnodes.h:173
#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:556
bool constisnull
Definition: primnodes.h:175
static Constraint* _copyConstraint ( const Constraint from)
static

Definition at line 2657 of file copyfuncs.c.

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

Referenced by copyObject().

2658 {
2659  Constraint *newnode = makeNode(Constraint);
2660 
2661  COPY_SCALAR_FIELD(contype);
2662  COPY_STRING_FIELD(conname);
2663  COPY_SCALAR_FIELD(deferrable);
2664  COPY_SCALAR_FIELD(initdeferred);
2665  COPY_LOCATION_FIELD(location);
2666  COPY_SCALAR_FIELD(is_no_inherit);
2667  COPY_NODE_FIELD(raw_expr);
2668  COPY_STRING_FIELD(cooked_expr);
2669  COPY_NODE_FIELD(keys);
2670  COPY_NODE_FIELD(exclusions);
2672  COPY_STRING_FIELD(indexname);
2673  COPY_STRING_FIELD(indexspace);
2674  COPY_STRING_FIELD(access_method);
2675  COPY_NODE_FIELD(where_clause);
2676  COPY_NODE_FIELD(pktable);
2677  COPY_NODE_FIELD(fk_attrs);
2678  COPY_NODE_FIELD(pk_attrs);
2679  COPY_SCALAR_FIELD(fk_matchtype);
2680  COPY_SCALAR_FIELD(fk_upd_action);
2681  COPY_SCALAR_FIELD(fk_del_action);
2682  COPY_NODE_FIELD(old_conpfeqop);
2683  COPY_SCALAR_FIELD(old_pktable_oid);
2684  COPY_SCALAR_FIELD(skip_validation);
2685  COPY_SCALAR_FIELD(initially_valid);
2686 
2687  return newnode;
2688 }
#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:556
static ConstraintsSetStmt* _copyConstraintsSetStmt ( const ConstraintsSetStmt from)
static

Definition at line 4052 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

4053 {
4055 
4056  COPY_NODE_FIELD(constraints);
4057  COPY_SCALAR_FIELD(deferred);
4058 
4059  return newnode;
4060 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static ConvertRowtypeExpr* _copyConvertRowtypeExpr ( const ConvertRowtypeExpr from)
static

Definition at line 1613 of file copyfuncs.c.

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

Referenced by copyObject().

1614 {
1616 
1618  COPY_SCALAR_FIELD(resulttype);
1619  COPY_SCALAR_FIELD(convertformat);
1620  COPY_LOCATION_FIELD(location);
1621 
1622  return newnode;
1623 }
#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:556
void * arg
static CopyStmt* _copyCopyStmt ( const CopyStmt from)
static

Definition at line 3040 of file copyfuncs.c.

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

Referenced by copyObject().

3041 {
3042  CopyStmt *newnode = makeNode(CopyStmt);
3043 
3044  COPY_NODE_FIELD(relation);
3045  COPY_NODE_FIELD(query);
3046  COPY_NODE_FIELD(attlist);
3047  COPY_SCALAR_FIELD(is_from);
3048  COPY_SCALAR_FIELD(is_program);
3051 
3052  return newnode;
3053 }
#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:556
static char * filename
Definition: pg_dumpall.c:84
static CreateAmStmt* _copyCreateAmStmt ( const CreateAmStmt from)
static

Definition at line 3919 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3920 {
3921  CreateAmStmt *newnode = makeNode(CreateAmStmt);
3922 
3923  COPY_STRING_FIELD(amname);
3924  COPY_NODE_FIELD(handler_name);
3925  COPY_SCALAR_FIELD(amtype);
3926 
3927  return newnode;
3928 }
#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:556
static CreateCastStmt* _copyCreateCastStmt ( const CreateCastStmt from)
static

Definition at line 4103 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

4104 {
4106 
4107  COPY_NODE_FIELD(sourcetype);
4108  COPY_NODE_FIELD(targettype);
4109  COPY_NODE_FIELD(func);
4110  COPY_SCALAR_FIELD(context);
4111  COPY_SCALAR_FIELD(inout);
4112 
4113  return newnode;
4114 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static CreateConversionStmt* _copyCreateConversionStmt ( const CreateConversionStmt from)
static

Definition at line 4089 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

4090 {
4092 
4093  COPY_NODE_FIELD(conversion_name);
4094  COPY_STRING_FIELD(for_encoding_name);
4095  COPY_STRING_FIELD(to_encoding_name);
4096  COPY_NODE_FIELD(func_name);
4097  COPY_SCALAR_FIELD(def);
4098 
4099  return newnode;
4100 }
#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:556
static CreatedbStmt* _copyCreatedbStmt ( const CreatedbStmt from)
static

Definition at line 3531 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, dbname, and makeNode.

Referenced by copyObject().

3532 {
3533  CreatedbStmt *newnode = makeNode(CreatedbStmt);
3534 
3537 
3538  return newnode;
3539 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
char * dbname
Definition: streamutil.c:41
static CreateDomainStmt* _copyCreateDomainStmt ( const CreateDomainStmt from)
static

Definition at line 3463 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObject().

3464 {
3466 
3467  COPY_NODE_FIELD(domainname);
3468  COPY_NODE_FIELD(typeName);
3469  COPY_NODE_FIELD(collClause);
3470  COPY_NODE_FIELD(constraints);
3471 
3472  return newnode;
3473 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static CreateEnumStmt* _copyCreateEnumStmt ( const CreateEnumStmt from)
static

Definition at line 3401 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObject().

3402 {
3404 
3405  COPY_NODE_FIELD(typeName);
3406  COPY_NODE_FIELD(vals);
3407 
3408  return newnode;
3409 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static CreateEventTrigStmt* _copyCreateEventTrigStmt ( const CreateEventTrigStmt from)
static

Definition at line 3954 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3955 {
3957 
3958  COPY_STRING_FIELD(trigname);
3959  COPY_STRING_FIELD(eventname);
3960  COPY_NODE_FIELD(whenclause);
3961  COPY_NODE_FIELD(funcname);
3962 
3963  return newnode;
3964 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
static CreateExtensionStmt* _copyCreateExtensionStmt ( const CreateExtensionStmt from)
static

Definition at line 3753 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3754 {
3756 
3757  COPY_STRING_FIELD(extname);
3758  COPY_SCALAR_FIELD(if_not_exists);
3760 
3761  return newnode;
3762 }
#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:556
static CreateFdwStmt* _copyCreateFdwStmt ( const CreateFdwStmt from)
static

Definition at line 3790 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3791 {
3792  CreateFdwStmt *newnode = makeNode(CreateFdwStmt);
3793 
3794  COPY_STRING_FIELD(fdwname);
3795  COPY_NODE_FIELD(func_options);
3797 
3798  return newnode;
3799 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
static CreateForeignServerStmt* _copyCreateForeignServerStmt ( const CreateForeignServerStmt from)
static

Definition at line 3814 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3815 {
3817 
3818  COPY_STRING_FIELD(servername);
3819  COPY_STRING_FIELD(servertype);
3820  COPY_STRING_FIELD(version);
3821  COPY_STRING_FIELD(fdwname);
3823 
3824  return newnode;
3825 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
static CreateForeignTableStmt* _copyCreateForeignTableStmt ( const CreateForeignTableStmt from)
static

Definition at line 3877 of file copyfuncs.c.

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

Referenced by copyObject().

3878 {
3880 
3881  CopyCreateStmtFields((const CreateStmt *) from, (CreateStmt *) newnode);
3882 
3883  COPY_STRING_FIELD(servername);
3885 
3886  return newnode;
3887 }
static void CopyCreateStmtFields(const CreateStmt *from, CreateStmt *newnode)
Definition: copyfuncs.c:3062
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
static CreateFunctionStmt* _copyCreateFunctionStmt ( const CreateFunctionStmt from)
static

Definition at line 3209 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

3210 {
3212 
3213  COPY_SCALAR_FIELD(replace);
3214  COPY_NODE_FIELD(funcname);
3215  COPY_NODE_FIELD(parameters);
3216  COPY_NODE_FIELD(returnType);
3218  COPY_NODE_FIELD(withClause);
3219 
3220  return newnode;
3221 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static CreateOpClassItem* _copyCreateOpClassItem ( const CreateOpClassItem from)
static

Definition at line 3491 of file copyfuncs.c.

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

Referenced by copyObject().

3492 {
3494 
3495  COPY_SCALAR_FIELD(itemtype);
3498  COPY_SCALAR_FIELD(number);
3499  COPY_NODE_FIELD(order_family);
3500  COPY_NODE_FIELD(class_args);
3501  COPY_NODE_FIELD(storedtype);
3502 
3503  return newnode;
3504 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
const char * name
Definition: encode.c:521
static CreateOpClassStmt* _copyCreateOpClassStmt ( const CreateOpClassStmt from)
static

Definition at line 3476 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3477 {
3479 
3480  COPY_NODE_FIELD(opclassname);
3481  COPY_NODE_FIELD(opfamilyname);
3482  COPY_STRING_FIELD(amname);
3483  COPY_NODE_FIELD(datatype);
3484  COPY_NODE_FIELD(items);
3485  COPY_SCALAR_FIELD(isDefault);
3486 
3487  return newnode;
3488 }
#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:556
static CreateOpFamilyStmt* _copyCreateOpFamilyStmt ( const CreateOpFamilyStmt from)
static

Definition at line 3507 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3508 {
3510 
3511  COPY_NODE_FIELD(opfamilyname);
3512  COPY_STRING_FIELD(amname);
3513 
3514  return newnode;
3515 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
static CreatePLangStmt* _copyCreatePLangStmt ( const CreatePLangStmt from)
static

Definition at line 3978 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3979 {
3981 
3982  COPY_SCALAR_FIELD(replace);
3983  COPY_STRING_FIELD(plname);
3984  COPY_NODE_FIELD(plhandler);
3985  COPY_NODE_FIELD(plinline);
3986  COPY_NODE_FIELD(plvalidator);
3987  COPY_SCALAR_FIELD(pltrusted);
3988 
3989  return newnode;
3990 }
#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:556
static CreatePolicyStmt* _copyCreatePolicyStmt ( const CreatePolicyStmt from)
static

Definition at line 4199 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

4200 {
4202 
4203  COPY_STRING_FIELD(policy_name);
4204  COPY_NODE_FIELD(table);
4205  COPY_STRING_FIELD(cmd_name);
4206  COPY_SCALAR_FIELD(permissive);
4207  COPY_NODE_FIELD(roles);
4208  COPY_NODE_FIELD(qual);
4209  COPY_NODE_FIELD(with_check);
4210 
4211  return newnode;
4212 }
#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:556
static CreatePublicationStmt* _copyCreatePublicationStmt ( const CreatePublicationStmt from)
static

Definition at line 4292 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

4293 {
4295 
4296  COPY_STRING_FIELD(pubname);
4298  COPY_NODE_FIELD(tables);
4299  COPY_SCALAR_FIELD(for_all_tables);
4300 
4301  return newnode;
4302 }
#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:556
static CreateRangeStmt* _copyCreateRangeStmt ( const CreateRangeStmt from)
static

Definition at line 3412 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObject().

3413 {
3415 
3416  COPY_NODE_FIELD(typeName);
3417  COPY_NODE_FIELD(params);
3418 
3419  return newnode;
3420 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static CreateRoleStmt* _copyCreateRoleStmt ( const CreateRoleStmt from)
static

Definition at line 3993 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3994 {
3996 
3997  COPY_SCALAR_FIELD(stmt_type);
3998  COPY_STRING_FIELD(role);
4000 
4001  return newnode;
4002 }
#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:556
static CreateSchemaStmt* _copyCreateSchemaStmt ( const CreateSchemaStmt from)
static

Definition at line 4076 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

4077 {
4079 
4080  COPY_STRING_FIELD(schemaname);
4081  COPY_NODE_FIELD(authrole);
4082  COPY_NODE_FIELD(schemaElts);
4083  COPY_SCALAR_FIELD(if_not_exists);
4084 
4085  return newnode;
4086 }
#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:556
static CreateSeqStmt* _copyCreateSeqStmt ( const CreateSeqStmt from)
static

Definition at line 3645 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

3646 {
3647  CreateSeqStmt *newnode = makeNode(CreateSeqStmt);
3648 
3649  COPY_NODE_FIELD(sequence);
3651  COPY_SCALAR_FIELD(ownerId);
3652  COPY_SCALAR_FIELD(if_not_exists);
3653 
3654  return newnode;
3655 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static CreateStmt* _copyCreateStmt ( const CreateStmt from)
static

Definition at line 3078 of file copyfuncs.c.

References CopyCreateStmtFields(), and makeNode.

Referenced by copyObject().

3079 {
3080  CreateStmt *newnode = makeNode(CreateStmt);
3081 
3082  CopyCreateStmtFields(from, newnode);
3083 
3084  return newnode;
3085 }
static void CopyCreateStmtFields(const CreateStmt *from, CreateStmt *newnode)
Definition: copyfuncs.c:3062
#define makeNode(_type_)
Definition: nodes.h:556
static CreateSubscriptionStmt* _copyCreateSubscriptionStmt ( const CreateSubscriptionStmt from)
static

Definition at line 4319 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

4320 {
4322 
4323  COPY_STRING_FIELD(subname);
4324  COPY_STRING_FIELD(conninfo);
4325  COPY_NODE_FIELD(publication);
4327 
4328  return newnode;
4329 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
static CreateTableAsStmt* _copyCreateTableAsStmt ( const CreateTableAsStmt from)
static

Definition at line 3598 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

3599 {
3601 
3602  COPY_NODE_FIELD(query);
3603  COPY_NODE_FIELD(into);
3604  COPY_SCALAR_FIELD(relkind);
3605  COPY_SCALAR_FIELD(is_select_into);
3606  COPY_SCALAR_FIELD(if_not_exists);
3607 
3608  return newnode;
3609 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static CreateTableSpaceStmt* _copyCreateTableSpaceStmt ( const CreateTableSpaceStmt from)
static

Definition at line 3703 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3704 {
3706 
3707  COPY_STRING_FIELD(tablespacename);
3708  COPY_NODE_FIELD(owner);
3709  COPY_STRING_FIELD(location);
3711 
3712  return newnode;
3713 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
static CreateTransformStmt* _copyCreateTransformStmt ( const CreateTransformStmt from)
static

Definition at line 3905 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3906 {
3908 
3909  COPY_SCALAR_FIELD(replace);
3910  COPY_NODE_FIELD(type_name);
3911  COPY_STRING_FIELD(lang);
3912  COPY_NODE_FIELD(fromsql);
3913  COPY_NODE_FIELD(tosql);
3914 
3915  return newnode;
3916 }
#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:556
static CreateTrigStmt* _copyCreateTrigStmt ( const CreateTrigStmt from)
static

Definition at line 3931 of file copyfuncs.c.

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

Referenced by copyObject().

3932 {
3934 
3935  COPY_STRING_FIELD(trigname);
3936  COPY_NODE_FIELD(relation);
3937  COPY_NODE_FIELD(funcname);
3939  COPY_SCALAR_FIELD(row);
3940  COPY_SCALAR_FIELD(timing);
3941  COPY_SCALAR_FIELD(events);
3942  COPY_NODE_FIELD(columns);
3943  COPY_NODE_FIELD(whenClause);
3944  COPY_SCALAR_FIELD(isconstraint);
3945  COPY_NODE_FIELD(transitionRels);
3946  COPY_SCALAR_FIELD(deferrable);
3947  COPY_SCALAR_FIELD(initdeferred);
3948  COPY_NODE_FIELD(constrrel);
3949 
3950  return newnode;
3951 }
#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:556
static CreateUserMappingStmt* _copyCreateUserMappingStmt ( const CreateUserMappingStmt from)
static

Definition at line 3841 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, makeNode, and user.

Referenced by copyObject().

3842 {
3844 
3846  COPY_STRING_FIELD(servername);
3848 
3849  return newnode;
3850 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
static char * user
Definition: pg_regress.c:90
static CteScan* _copyCteScan ( const CteScan from)
static

Definition at line 615 of file copyfuncs.c.

References COPY_SCALAR_FIELD, CopyScanFields(), and makeNode.

Referenced by copyObject().

616 {
617  CteScan *newnode = makeNode(CteScan);
618 
619  /*
620  * copy node superclass fields
621  */
622  CopyScanFields((const Scan *) from, (Scan *) newnode);
623 
624  /*
625  * copy remainder of node
626  */
627  COPY_SCALAR_FIELD(ctePlanId);
628  COPY_SCALAR_FIELD(cteParam);
629 
630  return newnode;
631 }
static void CopyScanFields(const Scan *from, Scan *newnode)
Definition: copyfuncs.c:370
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define makeNode(_type_)
Definition: nodes.h:556
static CurrentOfExpr* _copyCurrentOfExpr ( const CurrentOfExpr from)
static

Definition at line 1897 of file copyfuncs.c.

References COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

1898 {
1899  CurrentOfExpr *newnode = makeNode(CurrentOfExpr);
1900 
1901  COPY_SCALAR_FIELD(cvarno);
1902  COPY_STRING_FIELD(cursor_name);
1903  COPY_SCALAR_FIELD(cursor_param);
1904 
1905  return newnode;
1906 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
static CustomScan* _copyCustomScan ( const CustomScan from)
static

Definition at line 686 of file copyfuncs.c.

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

Referenced by copyObject().

687 {
688  CustomScan *newnode = makeNode(CustomScan);
689 
690  /*
691  * copy node superclass fields
692  */
693  CopyScanFields((const Scan *) from, (Scan *) newnode);
694 
695  /*
696  * copy remainder of node
697  */
698  COPY_SCALAR_FIELD(flags);
699  COPY_NODE_FIELD(custom_plans);
700  COPY_NODE_FIELD(custom_exprs);
701  COPY_NODE_FIELD(custom_private);
702  COPY_NODE_FIELD(custom_scan_tlist);
703  COPY_BITMAPSET_FIELD(custom_relids);
704 
705  /*
706  * NOTE: The method field of CustomScan is required to be a pointer to a
707  * static table of callback functions. So we don't copy the table itself,
708  * just reference the original one.
709  */
710  COPY_SCALAR_FIELD(methods);
711 
712  return newnode;
713 }
#define COPY_BITMAPSET_FIELD(fldname)
Definition: copyfuncs.c:49
static void CopyScanFields(const Scan *from, Scan *newnode)
Definition: copyfuncs.c:370
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static DeallocateStmt* _copyDeallocateStmt ( const DeallocateStmt from)
static

Definition at line 4140 of file copyfuncs.c.

References COPY_STRING_FIELD, makeNode, and name.

Referenced by copyObject().

4141 {
4143 
4145 
4146  return newnode;
4147 }
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
const char * name
Definition: encode.c:521
static DeclareCursorStmt* _copyDeclareCursorStmt ( const DeclareCursorStmt from)
static

Definition at line 3006 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3007 {
3009 
3010  COPY_STRING_FIELD(portalname);
3012  COPY_NODE_FIELD(query);
3013 
3014  return newnode;
3015 }
#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:556
static DefElem* _copyDefElem ( const DefElem from)
static

Definition at line 2691 of file copyfuncs.c.

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

Referenced by copyObject().

2692 {
2693  DefElem *newnode = makeNode(DefElem);
2694 
2695  COPY_STRING_FIELD(defnamespace);
2696  COPY_STRING_FIELD(defname);
2698  COPY_SCALAR_FIELD(defaction);
2699  COPY_LOCATION_FIELD(location);
2700 
2701  return newnode;
2702 }
#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:556
void * arg
static DefineStmt* _copyDefineStmt ( const DefineStmt from)
static

Definition at line 3099 of file copyfuncs.c.

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

Referenced by copyObject().

3100 {
3101  DefineStmt *newnode = makeNode(DefineStmt);
3102 
3103  COPY_SCALAR_FIELD(kind);
3104  COPY_SCALAR_FIELD(oldstyle);
3105  COPY_NODE_FIELD(defnames);
3107  COPY_NODE_FIELD(definition);
3108  COPY_SCALAR_FIELD(if_not_exists);
3109 
3110  return newnode;
3111 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static DeleteStmt* _copyDeleteStmt ( const DeleteStmt from)
static

Definition at line 2825 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObject().

2826 {
2827  DeleteStmt *newnode = makeNode(DeleteStmt);
2828 
2829  COPY_NODE_FIELD(relation);
2830  COPY_NODE_FIELD(usingClause);
2831  COPY_NODE_FIELD(whereClause);
2832  COPY_NODE_FIELD(returningList);
2833  COPY_NODE_FIELD(withClause);
2834 
2835  return newnode;
2836 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static DiscardStmt* _copyDiscardStmt ( const DiscardStmt from)
static

Definition at line 3693 of file copyfuncs.c.

References COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

3694 {
3695  DiscardStmt *newnode = makeNode(DiscardStmt);
3696 
3697  COPY_SCALAR_FIELD(target);
3698 
3699  return newnode;
3700 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define makeNode(_type_)
Definition: nodes.h:556
static DistinctExpr* _copyDistinctExpr ( const DistinctExpr from)
static

Definition at line 1393 of file copyfuncs.c.

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

Referenced by copyObject().

1394 {
1395  DistinctExpr *newnode = makeNode(DistinctExpr);
1396 
1397  COPY_SCALAR_FIELD(opno);
1398  COPY_SCALAR_FIELD(opfuncid);
1399  COPY_SCALAR_FIELD(opresulttype);
1400  COPY_SCALAR_FIELD(opretset);
1401  COPY_SCALAR_FIELD(opcollid);
1402  COPY_SCALAR_FIELD(inputcollid);
1404  COPY_LOCATION_FIELD(location);
1405 
1406  return newnode;
1407 }
#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:556
static DoStmt* _copyDoStmt ( const DoStmt from)
static

Definition at line 3248 of file copyfuncs.c.

References generate_unaccent_rules::args, COPY_NODE_FIELD, and makeNode.

Referenced by copyObject().

3249 {
3250  DoStmt *newnode = makeNode(DoStmt);
3251 
3253 
3254  return newnode;
3255 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static DropdbStmt* _copyDropdbStmt ( const DropdbStmt from)
static

Definition at line 3564 of file copyfuncs.c.

References COPY_SCALAR_FIELD, COPY_STRING_FIELD, dbname, and makeNode.

Referenced by copyObject().

3565 {
3566  DropdbStmt *newnode = makeNode(DropdbStmt);
3567 
3569  COPY_SCALAR_FIELD(missing_ok);
3570 
3571  return newnode;
3572 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
char * dbname
Definition: streamutil.c:41
static DropOwnedStmt* _copyDropOwnedStmt ( const DropOwnedStmt from)
static

Definition at line 4150 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

4151 {
4152  DropOwnedStmt *newnode = makeNode(DropOwnedStmt);
4153 
4154  COPY_NODE_FIELD(roles);
4155  COPY_SCALAR_FIELD(behavior);
4156 
4157  return newnode;
4158 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static DropRoleStmt* _copyDropRoleStmt ( const DropRoleStmt from)
static

Definition at line 4029 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

4030 {
4031  DropRoleStmt *newnode = makeNode(DropRoleStmt);
4032 
4033  COPY_NODE_FIELD(roles);
4034  COPY_SCALAR_FIELD(missing_ok);
4035 
4036  return newnode;
4037 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static DropStmt* _copyDropStmt ( const DropStmt from)
static

Definition at line 3114 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

3115 {
3116  DropStmt *newnode = makeNode(DropStmt);
3117 
3118  COPY_NODE_FIELD(objects);
3120  COPY_SCALAR_FIELD(removeType);
3121  COPY_SCALAR_FIELD(behavior);
3122  COPY_SCALAR_FIELD(missing_ok);
3123  COPY_SCALAR_FIELD(concurrent);
3124 
3125  return newnode;
3126 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static DropSubscriptionStmt* _copyDropSubscriptionStmt ( const DropSubscriptionStmt from)
static

Definition at line 4343 of file copyfuncs.c.

References COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

4344 {
4346 
4347  COPY_STRING_FIELD(subname);
4348  COPY_SCALAR_FIELD(drop_slot);
4349  COPY_SCALAR_FIELD(missing_ok);
4350 
4351  return newnode;
4352 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
static DropTableSpaceStmt* _copyDropTableSpaceStmt ( const DropTableSpaceStmt from)
static

Definition at line 3716 of file copyfuncs.c.

References COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3717 {
3719 
3720  COPY_STRING_FIELD(tablespacename);
3721  COPY_SCALAR_FIELD(missing_ok);
3722 
3723  return newnode;
3724 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
static DropUserMappingStmt* _copyDropUserMappingStmt ( const DropUserMappingStmt from)
static

Definition at line 3865 of file copyfuncs.c.

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

Referenced by copyObject().

3866 {
3868 
3870  COPY_STRING_FIELD(servername);
3871  COPY_SCALAR_FIELD(missing_ok);
3872 
3873  return newnode;
3874 }
#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:556
static char * user
Definition: pg_regress.c:90
static ExecuteStmt* _copyExecuteStmt ( const ExecuteStmt from)
static

Definition at line 4129 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_STRING_FIELD, makeNode, and name.

Referenced by copyObject().

4130 {
4131  ExecuteStmt *newnode = makeNode(ExecuteStmt);
4132 
4134  COPY_NODE_FIELD(params);
4135 
4136  return newnode;
4137 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
const char * name
Definition: encode.c:521
static ExplainStmt* _copyExplainStmt ( const ExplainStmt from)
static

Definition at line 3587 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObject().

3588 {
3589  ExplainStmt *newnode = makeNode(ExplainStmt);
3590 
3591  COPY_NODE_FIELD(query);
3593 
3594  return newnode;
3595 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static ExtensibleNode* _copyExtensibleNode ( const ExtensibleNode from)
static

Definition at line 4401 of file copyfuncs.c.

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

Referenced by copyObject().

4402 {
4403  ExtensibleNode *newnode;
4404  const ExtensibleNodeMethods *methods;
4405 
4406  methods = GetExtensibleNodeMethods(from->extnodename, false);
4407  newnode = (ExtensibleNode *) newNode(methods->node_size,
4409  COPY_STRING_FIELD(extnodename);
4410 
4411  /* copy the private fields */
4412  methods->nodeCopy(newnode, from);
4413 
4414  return newnode;
4415 }
void(* nodeCopy)(struct ExtensibleNode *newnode, const struct ExtensibleNode *oldnode)
Definition: extensible.h:64
#define newNode(size, tag)
Definition: nodes.h:546
#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 3168 of file copyfuncs.c.

References COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3169 {
3170  FetchStmt *newnode = makeNode(FetchStmt);
3171 
3172  COPY_SCALAR_FIELD(direction);
3173  COPY_SCALAR_FIELD(howMany);
3174  COPY_STRING_FIELD(portalname);
3175  COPY_SCALAR_FIELD(ismove);
3176 
3177  return newnode;
3178 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
static FieldSelect* _copyFieldSelect ( const FieldSelect from)
static

Definition at line 1525 of file copyfuncs.c.

References arg, COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

1526 {
1527  FieldSelect *newnode = makeNode(FieldSelect);
1528 
1530  COPY_SCALAR_FIELD(fieldnum);
1531  COPY_SCALAR_FIELD(resulttype);
1532  COPY_SCALAR_FIELD(resulttypmod);
1533  COPY_SCALAR_FIELD(resultcollid);
1534 
1535  return newnode;
1536 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
void * arg
static FieldStore* _copyFieldStore ( const FieldStore from)
static

Definition at line 1542 of file copyfuncs.c.

References arg, COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

1543 {
1544  FieldStore *newnode = makeNode(FieldStore);
1545 
1547  COPY_NODE_FIELD(newvals);
1548  COPY_NODE_FIELD(fieldnums);
1549  COPY_SCALAR_FIELD(resulttype);
1550 
1551  return newnode;
1552 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
void * arg
static ForeignKeyCacheInfo* _copyForeignKeyCacheInfo ( const ForeignKeyCacheInfo from)
static

Definition at line 4452 of file copyfuncs.c.

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

Referenced by copyObject().

4453 {
4455 
4456  COPY_SCALAR_FIELD(conrelid);
4457  COPY_SCALAR_FIELD(confrelid);
4458  COPY_SCALAR_FIELD(nkeys);
4459  /* COPY_SCALAR_FIELD might work for these, but let's not assume that */
4460  memcpy(newnode->conkey, from->conkey, sizeof(newnode->conkey));
4461  memcpy(newnode->confkey, from->confkey, sizeof(newnode->confkey));
4462  memcpy(newnode->conpfeqop, from->conpfeqop, sizeof(newnode->conpfeqop));
4463 
4464  return newnode;
4465 }
AttrNumber conkey[INDEX_MAX_KEYS]
Definition: rel.h:239
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define makeNode(_type_)
Definition: nodes.h:556
Oid conpfeqop[INDEX_MAX_KEYS]
Definition: rel.h:241
AttrNumber confkey[INDEX_MAX_KEYS]
Definition: rel.h:240
static ForeignScan* _copyForeignScan ( const ForeignScan from)
static

Definition at line 658 of file copyfuncs.c.

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

Referenced by copyObject().

659 {
660  ForeignScan *newnode = makeNode(ForeignScan);
661 
662  /*
663  * copy node superclass fields
664  */
665  CopyScanFields((const Scan *) from, (Scan *) newnode);
666 
667  /*
668  * copy remainder of node
669  */
670  COPY_SCALAR_FIELD(operation);
671  COPY_SCALAR_FIELD(fs_server);
672  COPY_NODE_FIELD(fdw_exprs);
673  COPY_NODE_FIELD(fdw_private);
674  COPY_NODE_FIELD(fdw_scan_tlist);
675  COPY_NODE_FIELD(fdw_recheck_quals);
676  COPY_BITMAPSET_FIELD(fs_relids);
677  COPY_SCALAR_FIELD(fsSystemCol);
678 
679  return newnode;
680 }
#define COPY_BITMAPSET_FIELD(fldname)
Definition: copyfuncs.c:49
static void CopyScanFields(const Scan *from, Scan *newnode)
Definition: copyfuncs.c:370
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static FromExpr* _copyFromExpr ( const FromExpr from)
static

Definition at line 1979 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObject().

1980 {
1981  FromExpr *newnode = makeNode(FromExpr);
1982 
1983  COPY_NODE_FIELD(fromlist);
1984  COPY_NODE_FIELD(quals);
1985 
1986  return newnode;
1987 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static FuncCall* _copyFuncCall ( const FuncCall from)
static

Definition at line 2419 of file copyfuncs.c.

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

Referenced by copyObject().

2420 {
2421  FuncCall *newnode = makeNode(FuncCall);
2422 
2423  COPY_NODE_FIELD(funcname);
2425  COPY_NODE_FIELD(agg_order);
2426  COPY_NODE_FIELD(agg_filter);
2427  COPY_SCALAR_FIELD(agg_within_group);
2428  COPY_SCALAR_FIELD(agg_star);
2429  COPY_SCALAR_FIELD(agg_distinct);
2430  COPY_SCALAR_FIELD(func_variadic);
2431  COPY_NODE_FIELD(over);
2432  COPY_LOCATION_FIELD(location);
2433 
2434  return newnode;
2435 }
#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:556
static FuncExpr* _copyFuncExpr ( const FuncExpr from)
static

Definition at line 1336 of file copyfuncs.c.

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

Referenced by copyObject().

1337 {
1338  FuncExpr *newnode = makeNode(FuncExpr);
1339 
1340  COPY_SCALAR_FIELD(funcid);
1341  COPY_SCALAR_FIELD(funcresulttype);
1342  COPY_SCALAR_FIELD(funcretset);
1343  COPY_SCALAR_FIELD(funcvariadic);
1344  COPY_SCALAR_FIELD(funcformat);
1345  COPY_SCALAR_FIELD(funccollid);
1346  COPY_SCALAR_FIELD(inputcollid);
1348  COPY_LOCATION_FIELD(location);
1349 
1350  return newnode;
1351 }
#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:556
static FunctionParameter* _copyFunctionParameter ( const FunctionParameter from)
static

Definition at line 3224 of file copyfuncs.c.

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

Referenced by copyObject().

3225 {
3227 
3229  COPY_NODE_FIELD(argType);
3230  COPY_SCALAR_FIELD(mode);
3231  COPY_NODE_FIELD(defexpr);
3232 
3233  return newnode;
3234 }
#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:556
const char * name
Definition: encode.c:521
static FunctionScan* _copyFunctionScan ( const FunctionScan from)
static

Definition at line 572 of file copyfuncs.c.

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

Referenced by copyObject().

573 {
574  FunctionScan *newnode = makeNode(FunctionScan);
575 
576  /*
577  * copy node superclass fields
578  */
579  CopyScanFields((const Scan *) from, (Scan *) newnode);
580 
581  /*
582  * copy remainder of node
583  */
585  COPY_SCALAR_FIELD(funcordinality);
586 
587  return newnode;
588 }
static void CopyScanFields(const Scan *from, Scan *newnode)
Definition: copyfuncs.c:370
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static const struct fns functions
Definition: regcomp.c:301
static FuncWithArgs* _copyFuncWithArgs ( const FuncWithArgs from)
static

Definition at line 2958 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObject().

2959 {
2960  FuncWithArgs *newnode = makeNode(FuncWithArgs);
2961 
2962  COPY_NODE_FIELD(funcname);
2963  COPY_NODE_FIELD(funcargs);
2964 
2965  return newnode;
2966 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static Gather* _copyGather ( const Gather from)
static

Definition at line 343 of file copyfuncs.c.

References COPY_SCALAR_FIELD, CopyPlanFields(), and makeNode.

Referenced by copyObject().

344 {
345  Gather *newnode = makeNode(Gather);
346 
347  /*
348  * copy node superclass fields
349  */
350  CopyPlanFields((const Plan *) from, (Plan *) newnode);
351 
352  /*
353  * copy remainder of node
354  */
355  COPY_SCALAR_FIELD(num_workers);
356  COPY_SCALAR_FIELD(single_copy);
357  COPY_SCALAR_FIELD(invisible);
358 
359  return newnode;
360 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
static void CopyPlanFields(const Plan *from, Plan *newnode)
Definition: copyfuncs.c:113
#define makeNode(_type_)
Definition: nodes.h:556
static GrantRoleStmt* _copyGrantRoleStmt ( const GrantRoleStmt from)
static

Definition at line 2980 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

2981 {
2982  GrantRoleStmt *newnode = makeNode(GrantRoleStmt);
2983 
2984  COPY_NODE_FIELD(granted_roles);
2985  COPY_NODE_FIELD(grantee_roles);
2986  COPY_SCALAR_FIELD(is_grant);
2987  COPY_SCALAR_FIELD(admin_opt);
2988  COPY_NODE_FIELD(grantor);
2989  COPY_SCALAR_FIELD(behavior);
2990 
2991  return newnode;
2992 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static GrantStmt* _copyGrantStmt ( const GrantStmt from)
static

Definition at line 2941 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

2942 {
2943  GrantStmt *newnode = makeNode(GrantStmt);
2944 
2945  COPY_SCALAR_FIELD(is_grant);
2946  COPY_SCALAR_FIELD(targtype);
2947  COPY_SCALAR_FIELD(objtype);
2948  COPY_NODE_FIELD(objects);
2949  COPY_NODE_FIELD(privileges);
2950  COPY_NODE_FIELD(grantees);
2951  COPY_SCALAR_FIELD(grant_option);
2952  COPY_SCALAR_FIELD(behavior);
2953 
2954  return newnode;
2955 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static Group* _copyGroup ( const Group from)
static

Definition at line 866 of file copyfuncs.c.

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

Referenced by copyObject().

867 {
868  Group *newnode = makeNode(Group);
869 
870  CopyPlanFields((const Plan *) from, (Plan *) newnode);
871 
872  COPY_SCALAR_FIELD(numCols);
873  COPY_POINTER_FIELD(grpColIdx, from->numCols * sizeof(AttrNumber));
874  COPY_POINTER_FIELD(grpOperators, from->numCols * sizeof(Oid));
875 
876  return newnode;
877 }
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:113
int numCols
Definition: plannodes.h:711
#define makeNode(_type_)
Definition: nodes.h:556
int16 AttrNumber
Definition: attnum.h:21
static GroupingFunc* _copyGroupingFunc ( const GroupingFunc from)
static

Definition at line 1277 of file copyfuncs.c.

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

Referenced by copyObject().

1278 {
1279  GroupingFunc *newnode = makeNode(GroupingFunc);
1280 
1282  COPY_NODE_FIELD(refs);
1283  COPY_NODE_FIELD(cols);
1284  COPY_SCALAR_FIELD(agglevelsup);
1285  COPY_LOCATION_FIELD(location);
1286 
1287  return newnode;
1288 }
#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:556
static GroupingSet* _copyGroupingSet ( const GroupingSet from)
static

Definition at line 2251 of file copyfuncs.c.

References COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

2252 {
2253  GroupingSet *newnode = makeNode(GroupingSet);
2254 
2255  COPY_SCALAR_FIELD(kind);
2256  COPY_NODE_FIELD(content);
2257  COPY_LOCATION_FIELD(location);
2258 
2259  return newnode;
2260 }
#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:556
static Hash* _copyHash ( const Hash from)
static

Definition at line 962 of file copyfuncs.c.

References COPY_SCALAR_FIELD, CopyPlanFields(), and makeNode.

Referenced by copyObject().

963 {
964  Hash *newnode = makeNode(Hash);
965 
966  /*
967  * copy node superclass fields
968  */
969  CopyPlanFields((const Plan *) from, (Plan *) newnode);
970 
971  /*
972  * copy remainder of node
973  */
974  COPY_SCALAR_FIELD(skewTable);
975  COPY_SCALAR_FIELD(skewColumn);
976  COPY_SCALAR_FIELD(skewInherit);
977  COPY_SCALAR_FIELD(skewColType);
978  COPY_SCALAR_FIELD(skewColTypmod);
979 
980  return newnode;
981 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
static void CopyPlanFields(const Plan *from, Plan *newnode)
Definition: copyfuncs.c:113
#define makeNode(_type_)
Definition: nodes.h:556
static HashJoin* _copyHashJoin ( const HashJoin from)
static

Definition at line 804 of file copyfuncs.c.

References COPY_NODE_FIELD, CopyJoinFields(), and makeNode.

Referenced by copyObject().

805 {
806  HashJoin *newnode = makeNode(HashJoin);
807 
808  /*
809  * copy node superclass fields
810  */
811  CopyJoinFields((const Join *) from, (Join *) newnode);
812 
813  /*
814  * copy remainder of node
815  */
816  COPY_NODE_FIELD(hashclauses);
817 
818  return newnode;
819 }
static void CopyJoinFields(const Join *from, Join *newnode)
Definition: copyfuncs.c:722
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static ImportForeignSchemaStmt* _copyImportForeignSchemaStmt ( const ImportForeignSchemaStmt from)
static

Definition at line 3890 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3891 {
3893 
3894  COPY_STRING_FIELD(server_name);
3895  COPY_STRING_FIELD(remote_schema);
3896  COPY_STRING_FIELD(local_schema);
3897  COPY_SCALAR_FIELD(list_type);
3898  COPY_NODE_FIELD(table_list);
3900 
3901  return newnode;
3902 }
#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:556
static IndexElem* _copyIndexElem ( const IndexElem from)
static

Definition at line 2618 of file copyfuncs.c.

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

Referenced by copyObject().

2619 {
2620  IndexElem *newnode = makeNode(IndexElem);
2621 
2623  COPY_NODE_FIELD(expr);
2624  COPY_STRING_FIELD(indexcolname);
2625  COPY_NODE_FIELD(collation);
2626  COPY_NODE_FIELD(opclass);
2627  COPY_SCALAR_FIELD(ordering);
2628  COPY_SCALAR_FIELD(nulls_ordering);
2629 
2630  return newnode;
2631 }
#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:556
const char * name
Definition: encode.c:521
static IndexOnlyScan* _copyIndexOnlyScan ( const IndexOnlyScan from)
static

Definition at line 461 of file copyfuncs.c.

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

Referenced by copyObject().

462 {
464 
465  /*
466  * copy node superclass fields
467  */
468  CopyScanFields((const Scan *) from, (Scan *) newnode);
469 
470  /*
471  * copy remainder of node
472  */
473  COPY_SCALAR_FIELD(indexid);
474  COPY_NODE_FIELD(indexqual);
475  COPY_NODE_FIELD(indexorderby);
476  COPY_NODE_FIELD(indextlist);
477  COPY_SCALAR_FIELD(indexorderdir);
478 
479  return newnode;
480 }
static void CopyScanFields(const Scan *from, Scan *newnode)
Definition: copyfuncs.c:370
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static IndexScan* _copyIndexScan ( const IndexScan from)
static

Definition at line 434 of file copyfuncs.c.

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

Referenced by copyObject().

435 {
436  IndexScan *newnode = makeNode(IndexScan);
437 
438  /*
439  * copy node superclass fields
440  */
441  CopyScanFields((const Scan *) from, (Scan *) newnode);
442 
443  /*
444  * copy remainder of node
445  */
446  COPY_SCALAR_FIELD(indexid);
447  COPY_NODE_FIELD(indexqual);
448  COPY_NODE_FIELD(indexqualorig);
449  COPY_NODE_FIELD(indexorderby);
450  COPY_NODE_FIELD(indexorderbyorig);
451  COPY_NODE_FIELD(indexorderbyops);
452  COPY_SCALAR_FIELD(indexorderdir);
453 
454  return newnode;
455 }
static void CopyScanFields(const Scan *from, Scan *newnode)
Definition: copyfuncs.c:370
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static IndexStmt* _copyIndexStmt ( const IndexStmt from)
static

Definition at line 3181 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3182 {
3183  IndexStmt *newnode = makeNode(IndexStmt);
3184 
3185  COPY_STRING_FIELD(idxname);
3186  COPY_NODE_FIELD(relation);
3187  COPY_STRING_FIELD(accessMethod);
3188  COPY_STRING_FIELD(tableSpace);
3189  COPY_NODE_FIELD(indexParams);
3191  COPY_NODE_FIELD(whereClause);
3192  COPY_NODE_FIELD(excludeOpNames);
3193  COPY_STRING_FIELD(idxcomment);
3194  COPY_SCALAR_FIELD(indexOid);
3195  COPY_SCALAR_FIELD(oldNode);
3196  COPY_SCALAR_FIELD(unique);
3197  COPY_SCALAR_FIELD(primary);
3198  COPY_SCALAR_FIELD(isconstraint);
3199  COPY_SCALAR_FIELD(deferrable);
3200  COPY_SCALAR_FIELD(initdeferred);
3201  COPY_SCALAR_FIELD(transformed);
3202  COPY_SCALAR_FIELD(concurrent);
3203  COPY_SCALAR_FIELD(if_not_exists);
3204 
3205  return newnode;
3206 }
#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:556
static InferClause* _copyInferClause ( const InferClause from)
static

Definition at line 2306 of file copyfuncs.c.

References COPY_LOCATION_FIELD, COPY_NODE_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

2307 {
2308  InferClause *newnode = makeNode(InferClause);
2309 
2310  COPY_NODE_FIELD(indexElems);
2311  COPY_NODE_FIELD(whereClause);
2312  COPY_STRING_FIELD(conname);
2313  COPY_LOCATION_FIELD(location);
2314 
2315  return newnode;
2316 }
#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:556
static InferenceElem* _copyInferenceElem ( const InferenceElem from)
static

Definition at line 1912 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

1913 {
1914  InferenceElem *newnode = makeNode(InferenceElem);
1915 
1916  COPY_NODE_FIELD(expr);
1917  COPY_SCALAR_FIELD(infercollid);
1918  COPY_SCALAR_FIELD(inferopclass);
1919 
1920  return newnode;
1921 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static InsertStmt* _copyInsertStmt ( const InsertStmt from)
static

Definition at line 2810 of file copyfuncs.c.

References COPY_NODE_FIELD, and makeNode.

Referenced by copyObject().

2811 {
2812  InsertStmt *newnode = makeNode(InsertStmt);
2813 
2814  COPY_NODE_FIELD(relation);
2815  COPY_NODE_FIELD(cols);
2816  COPY_NODE_FIELD(selectStmt);
2817  COPY_NODE_FIELD(onConflictClause);
2818  COPY_NODE_FIELD(returningList);
2819  COPY_NODE_FIELD(withClause);
2820 
2821  return newnode;
2822 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static IntoClause* _copyIntoClause ( const IntoClause from)
static

Definition at line 1145 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

1146 {
1147  IntoClause *newnode = makeNode(IntoClause);
1148 
1149  COPY_NODE_FIELD(rel);
1150  COPY_NODE_FIELD(colNames);
1152  COPY_SCALAR_FIELD(onCommit);
1153  COPY_STRING_FIELD(tableSpaceName);
1154  COPY_NODE_FIELD(viewQuery);
1155  COPY_SCALAR_FIELD(skipData);
1156 
1157  return newnode;
1158 }
#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:556
static Join* _copyJoin ( const Join from)
static

Definition at line 735 of file copyfuncs.c.

References CopyJoinFields(), and makeNode.

Referenced by copyObject().

736 {
737  Join *newnode = makeNode(Join);
738 
739  /*
740  * copy node superclass fields
741  */
742  CopyJoinFields(from, newnode);
743 
744  return newnode;
745 }
static void CopyJoinFields(const Join *from, Join *newnode)
Definition: copyfuncs.c:722
#define makeNode(_type_)
Definition: nodes.h:556
static JoinExpr* _copyJoinExpr ( const JoinExpr from)
static

Definition at line 1959 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

1960 {
1961  JoinExpr *newnode = makeNode(JoinExpr);
1962 
1963  COPY_SCALAR_FIELD(jointype);
1964  COPY_SCALAR_FIELD(isNatural);
1965  COPY_NODE_FIELD(larg);
1966  COPY_NODE_FIELD(rarg);
1967  COPY_NODE_FIELD(usingClause);
1968  COPY_NODE_FIELD(quals);
1969  COPY_NODE_FIELD(alias);
1970  COPY_SCALAR_FIELD(rtindex);
1971 
1972  return newnode;
1973 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static Limit* _copyLimit ( const Limit from)
static

Definition at line 1037 of file copyfuncs.c.

References COPY_NODE_FIELD, CopyPlanFields(), and makeNode.

Referenced by copyObject().

1038 {
1039  Limit *newnode = makeNode(Limit);
1040 
1041  /*
1042  * copy node superclass fields
1043  */
1044  CopyPlanFields((const Plan *) from, (Plan *) newnode);
1045 
1046  /*
1047  * copy remainder of node
1048  */
1049  COPY_NODE_FIELD(limitOffset);
1050  COPY_NODE_FIELD(limitCount);
1051 
1052  return newnode;
1053 }
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
static void CopyPlanFields(const Plan *from, Plan *newnode)
Definition: copyfuncs.c:113
#define makeNode(_type_)
Definition: nodes.h:556
static List* _copyList ( const List from)
static

Definition at line 4369 of file copyfuncs.c.

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

Referenced by copyObject().

4370 {
4371  List *new;
4372  ListCell *curr_old;
4373  ListCell *prev_new;
4374 
4375  Assert(list_length(from) >= 1);
4376 
4377  new = makeNode(List);
4378  new->length = from->length;
4379 
4380  COPY_NODE_CELL(new->head, from->head);
4381  prev_new = new->head;
4382  curr_old = lnext(from->head);
4383 
4384  while (curr_old)
4385  {
4386  COPY_NODE_CELL(prev_new->next, curr_old);
4387  prev_new = prev_new->next;
4388  curr_old = curr_old->next;
4389  }
4390  prev_new->next = NULL;
4391  new->tail = prev_new;
4392 
4393  return new;
4394 }
#define lnext(lc)
Definition: pg_list.h:105
#define COPY_NODE_CELL(new, old)
Definition: copyfuncs.c:4364
#define makeNode(_type_)
Definition: nodes.h:556
ListCell * next
Definition: pg_list.h:61
#define NULL
Definition: c.h:226
#define Assert(condition)
Definition: c.h:671
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 3358 of file copyfuncs.c.

References COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3359 {
3360  ListenStmt *newnode = makeNode(ListenStmt);
3361 
3362  COPY_STRING_FIELD(conditionname);
3363 
3364  return newnode;
3365 }
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
static LoadStmt* _copyLoadStmt ( const LoadStmt from)
static

Definition at line 3453 of file copyfuncs.c.

References COPY_STRING_FIELD, filename, and makeNode.

Referenced by copyObject().

3454 {
3455  LoadStmt *newnode = makeNode(LoadStmt);
3456 
3458 
3459  return newnode;
3460 }
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
static char * filename
Definition: pg_dumpall.c:84
static LockingClause* _copyLockingClause ( const LockingClause from)
static

Definition at line 2705 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

2706 {
2707  LockingClause *newnode = makeNode(LockingClause);
2708 
2709  COPY_NODE_FIELD(lockedRels);
2710  COPY_SCALAR_FIELD(strength);
2711  COPY_SCALAR_FIELD(waitPolicy);
2712 
2713  return newnode;
2714 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static LockRows* _copyLockRows ( const LockRows from)
static

Definition at line 1015 of file copyfuncs.c.

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

Referenced by copyObject().

1016 {
1017  LockRows *newnode = makeNode(LockRows);
1018 
1019  /*
1020  * copy node superclass fields
1021  */
1022  CopyPlanFields((const Plan *) from, (Plan *) newnode);
1023 
1024  /*
1025  * copy remainder of node
1026  */
1027  COPY_NODE_FIELD(rowMarks);
1028  COPY_SCALAR_FIELD(epqParam);
1029 
1030  return newnode;
1031 }
#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:113
#define makeNode(_type_)
Definition: nodes.h:556
static LockStmt* _copyLockStmt ( const LockStmt from)
static

Definition at line 4040 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

4041 {
4042  LockStmt *newnode = makeNode(LockStmt);
4043 
4044  COPY_NODE_FIELD(relations);
4045  COPY_SCALAR_FIELD(mode);
4046  COPY_SCALAR_FIELD(nowait);
4047 
4048  return newnode;
4049 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static Material* _copyMaterial ( const Material from)
static

Definition at line 826 of file copyfuncs.c.

References CopyPlanFields(), and makeNode.

Referenced by copyObject().

827 {
828  Material *newnode = makeNode(Material);
829 
830  /*
831  * copy node superclass fields
832  */
833  CopyPlanFields((const Plan *) from, (Plan *) newnode);
834 
835  return newnode;
836 }
static void CopyPlanFields(const Plan *from, Plan *newnode)
Definition: copyfuncs.c:113
#define makeNode(_type_)
Definition: nodes.h:556
static MergeAppend* _copyMergeAppend ( const MergeAppend from)
static

Definition at line 247 of file copyfuncs.c.

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

Referenced by copyObject().

248 {
249  MergeAppend *newnode = makeNode(MergeAppend);
250 
251  /*
252  * copy node superclass fields
253  */
254  CopyPlanFields((const Plan *) from, (Plan *) newnode);
255 
256  /*
257  * copy remainder of node
258  */
259  COPY_NODE_FIELD(mergeplans);
260  COPY_SCALAR_FIELD(numCols);
261  COPY_POINTER_FIELD(sortColIdx, from->numCols * sizeof(AttrNumber));
262  COPY_POINTER_FIELD(sortOperators, from->numCols * sizeof(Oid));
263  COPY_POINTER_FIELD(collations, from->numCols * sizeof(Oid));
264  COPY_POINTER_FIELD(nullsFirst, from->numCols * sizeof(bool));
265 
266  return newnode;
267 }
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:113
#define makeNode(_type_)
Definition: nodes.h:556
int16 AttrNumber
Definition: attnum.h:21
static MergeJoin* _copyMergeJoin ( const MergeJoin from)
static

Definition at line 774 of file copyfuncs.c.

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

Referenced by copyObject().

775 {
776  MergeJoin *newnode = makeNode(MergeJoin);
777  int numCols;
778 
779  /*
780  * copy node superclass fields
781  */
782  CopyJoinFields((const Join *) from, (Join *) newnode);
783 
784  /*
785  * copy remainder of node
786  */
787  COPY_NODE_FIELD(mergeclauses);
788  numCols = list_length(from->mergeclauses);
789  if (numCols > 0)
790  {
791  COPY_POINTER_FIELD(mergeFamilies, numCols * sizeof(Oid));
792  COPY_POINTER_FIELD(mergeCollations, numCols * sizeof(Oid));
793  COPY_POINTER_FIELD(mergeStrategies, numCols * sizeof(int));
794  COPY_POINTER_FIELD(mergeNullsFirst, numCols * sizeof(bool));
795  }
796 
797  return newnode;
798 }
unsigned int Oid
Definition: postgres_ext.h:31
List * mergeclauses
Definition: plannodes.h:661
static void CopyJoinFields(const Join *from, Join *newnode)
Definition: copyfuncs.c:722
#define COPY_POINTER_FIELD(fldname, sz)
Definition: copyfuncs.c:57
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static int list_length(const List *l)
Definition: pg_list.h:89
static MinMaxExpr* _copyMinMaxExpr ( const MinMaxExpr from)
static

Definition at line 1761 of file copyfuncs.c.

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

Referenced by copyObject().

1762 {
1763  MinMaxExpr *newnode = makeNode(MinMaxExpr);
1764 
1765  COPY_SCALAR_FIELD(minmaxtype);
1766  COPY_SCALAR_FIELD(minmaxcollid);
1767  COPY_SCALAR_FIELD(inputcollid);
1768  COPY_SCALAR_FIELD(op);
1770  COPY_LOCATION_FIELD(location);
1771 
1772  return newnode;
1773 }
#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:556
static ModifyTable* _copyModifyTable ( const ModifyTable from)
static

Definition at line 188 of file copyfuncs.c.

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

Referenced by copyObject().

189 {
190  ModifyTable *newnode = makeNode(ModifyTable);
191 
192  /*
193  * copy node superclass fields
194  */
195  CopyPlanFields((const Plan *) from, (Plan *) newnode);
196 
197  /*
198  * copy remainder of node
199  */
200  COPY_SCALAR_FIELD(operation);
201  COPY_SCALAR_FIELD(canSetTag);
202  COPY_SCALAR_FIELD(nominalRelation);
203  COPY_NODE_FIELD(resultRelations);
204  COPY_SCALAR_FIELD(resultRelIndex);
205  COPY_NODE_FIELD(plans);
206  COPY_NODE_FIELD(withCheckOptionLists);
207  COPY_NODE_FIELD(returningLists);
208  COPY_NODE_FIELD(fdwPrivLists);
209  COPY_BITMAPSET_FIELD(fdwDirectModifyPlans);
210  COPY_NODE_FIELD(rowMarks);
211  COPY_SCALAR_FIELD(epqParam);
212  COPY_SCALAR_FIELD(onConflictAction);
213  COPY_NODE_FIELD(arbiterIndexes);
214  COPY_NODE_FIELD(onConflictSet);
215  COPY_NODE_FIELD(onConflictWhere);
216  COPY_SCALAR_FIELD(exclRelRTI);
217  COPY_NODE_FIELD(exclRelTlist);
218 
219  return newnode;
220 }
#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:113
#define makeNode(_type_)
Definition: nodes.h:556
static MultiAssignRef* _copyMultiAssignRef ( const MultiAssignRef from)
static

Definition at line 2493 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

2494 {
2496 
2497  COPY_NODE_FIELD(source);
2498  COPY_SCALAR_FIELD(colno);
2499  COPY_SCALAR_FIELD(ncolumns);
2500 
2501  return newnode;
2502 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static NamedArgExpr* _copyNamedArgExpr ( const NamedArgExpr from)
static

Definition at line 1357 of file copyfuncs.c.

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

Referenced by copyObject().

1358 {
1359  NamedArgExpr *newnode = makeNode(NamedArgExpr);
1360 
1363  COPY_SCALAR_FIELD(argnumber);
1364  COPY_LOCATION_FIELD(location);
1365 
1366  return newnode;
1367 }
#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:556
const char * name
Definition: encode.c:521
void * arg
static NestLoop* _copyNestLoop ( const NestLoop from)
static

Definition at line 752 of file copyfuncs.c.

References COPY_NODE_FIELD, CopyJoinFields(), and makeNode.

Referenced by copyObject().

753 {
754  NestLoop *newnode = makeNode(NestLoop);
755 
756  /*
757  * copy node superclass fields
758  */
759  CopyJoinFields((const Join *) from, (Join *) newnode);
760 
761  /*
762  * copy remainder of node
763  */
764  COPY_NODE_FIELD(nestParams);
765 
766  return newnode;
767 }
static void CopyJoinFields(const Join *from, Join *newnode)
Definition: copyfuncs.c:722
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static NestLoopParam* _copyNestLoopParam ( const NestLoopParam from)
static

Definition at line 1059 of file copyfuncs.c.

References COPY_NODE_FIELD, COPY_SCALAR_FIELD, and makeNode.

Referenced by copyObject().

1060 {
1061  NestLoopParam *newnode = makeNode(NestLoopParam);
1062 
1063  COPY_SCALAR_FIELD(paramno);
1064  COPY_NODE_FIELD(paramval);
1065 
1066  return newnode;
1067 }
#define COPY_SCALAR_FIELD(fldname)
Definition: copyfuncs.c:41
#define COPY_NODE_FIELD(fldname)
Definition: copyfuncs.c:45
#define makeNode(_type_)
Definition: nodes.h:556
static NotifyStmt* _copyNotifyStmt ( const NotifyStmt from)
static

Definition at line 3347 of file copyfuncs.c.

References COPY_STRING_FIELD, and makeNode.

Referenced by copyObject().

3348 {
3349  NotifyStmt *newnode = makeNode(NotifyStmt);
3350 
3351  COPY_STRING_FIELD(conditionname);
3352  COPY_STRING_FIELD(payload);
3353 
3354  return newnode;
3355 }
#define COPY_STRING_FIELD(fldname)
Definition: copyfuncs.c:53
#define makeNode(_type_)
Definition: nodes.h:556
static NullIfExpr* _copyNullIfExpr ( const NullIfExpr from)
static

Definition at line 1413 of file copyfuncs.c.

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

Referenced by copyObject().

1414 {
1415  NullIfExpr *newnode = makeNode(NullIfExpr);
1416 
1417  COPY_SCALAR_FIELD(opno);
1418  COPY_SCALAR_FIELD(opfuncid);
1419  COPY_SCALAR_FIELD(opresulttype);
1420  COPY_SCALAR_FIELD(opretset);
1421  COPY_SCALAR_FIELD(opcollid);
1422  COPY_SCALAR_FIELD(inputcollid);
1424  COPY_LOCATION_FIELD(location);
1425 
1426  return newnode;
1427 }
#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:556
static NullTest* _copyNullTest ( const NullTest from)
static

Definition at line 1816 of file copyfuncs.c.

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

Referenced by copyObject().

1817 {
1818  NullTest *newnode = makeNode(NullTest);
1819 
1821  COPY_SCALAR_FIELD(nulltesttype);
1822  COPY_SCALAR_FIELD(argisrow);
1823  COPY_LOCATION_FIELD(location);
1824 
1825  return newnode;
1826 }
#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:556
void * arg
static