Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit570be1f

Browse files
committed
Re-export a few of createplan.c's make_xxx() functions.
CitusDB is using these and don't wish to redesign their code right now.I am not on board with this being a good idea, or a good precedent,but I lack the energy to fight about it.
1 parent7087166 commit570be1f

File tree

2 files changed

+11
-10
lines changed

2 files changed

+11
-10
lines changed

‎src/backend/optimizer/plan/createplan.c

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -242,16 +242,10 @@ static EquivalenceMember *find_ec_member_for_tle(EquivalenceClass *ec,
242242
TargetEntry*tle,
243243
Relidsrelids);
244244
staticSort*make_sort_from_pathkeys(Plan*lefttree,List*pathkeys);
245-
staticSort*make_sort_from_sortclauses(List*sortcls,Plan*lefttree);
246245
staticSort*make_sort_from_groupcols(List*groupcls,
247246
AttrNumber*grpColIdx,
248247
Plan*lefttree);
249248
staticMaterial*make_material(Plan*lefttree);
250-
staticAgg*make_agg(List*tlist,List*qual,AggStrategyaggstrategy,
251-
boolcombineStates,boolfinalizeAggs,
252-
intnumGroupCols,AttrNumber*grpColIdx,Oid*grpOperators,
253-
List*groupingSets,List*chain,
254-
doubledNumGroups,Plan*lefttree);
255249
staticWindowAgg*make_windowagg(List*tlist,Indexwinref,
256250
intpartNumCols,AttrNumber*partColIdx,Oid*partOperators,
257251
intordNumCols,AttrNumber*ordColIdx,Oid*ordOperators,
@@ -269,7 +263,6 @@ static SetOp *make_setop(SetOpCmd cmd, SetOpStrategy strategy, Plan *lefttree,
269263
List*distinctList,AttrNumberflagColIdx,intfirstFlag,
270264
longnumGroups);
271265
staticLockRows*make_lockrows(Plan*lefttree,List*rowMarks,intepqParam);
272-
staticLimit*make_limit(Plan*lefttree,Node*limitOffset,Node*limitCount);
273266
staticResult*make_result(List*tlist,Node*resconstantqual,Plan*subplan);
274267
staticModifyTable*make_modifytable(PlannerInfo*root,
275268
CmdTypeoperation,boolcanSetTag,
@@ -5500,7 +5493,7 @@ make_sort_from_pathkeys(Plan *lefttree, List *pathkeys)
55005493
* 'sortcls' is a list of SortGroupClauses
55015494
* 'lefttree' is the node which yields input tuples
55025495
*/
5503-
staticSort*
5496+
Sort*
55045497
make_sort_from_sortclauses(List*sortcls,Plan*lefttree)
55055498
{
55065499
List*sub_tlist=lefttree->targetlist;
@@ -5635,7 +5628,7 @@ materialize_finished_plan(Plan *subplan)
56355628
returnmatplan;
56365629
}
56375630

5638-
staticAgg*
5631+
Agg*
56395632
make_agg(List*tlist,List*qual,
56405633
AggStrategyaggstrategy,
56415634
boolcombineStates,boolfinalizeAggs,
@@ -5973,7 +5966,7 @@ make_lockrows(Plan *lefttree, List *rowMarks, int epqParam)
59735966
* make_limit
59745967
* Build a Limit plan node
59755968
*/
5976-
staticLimit*
5969+
Limit*
59775970
make_limit(Plan*lefttree,Node*limitOffset,Node*limitCount)
59785971
{
59795972
Limit*node=makeNode(Limit);

‎src/include/optimizer/planmain.h

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,14 @@ extern ForeignScan *make_foreignscan(List *qptlist, List *qpqual,
5555
externPlan*materialize_finished_plan(Plan*subplan);
5656
externboolis_projection_capable_path(Path*path);
5757
externboolis_projection_capable_plan(Plan*plan);
58+
/* External use of these functions is deprecated: */
59+
externSort*make_sort_from_sortclauses(List*sortcls,Plan*lefttree);
60+
externAgg*make_agg(List*tlist,List*qual,AggStrategyaggstrategy,
61+
boolcombineStates,boolfinalizeAggs,
62+
intnumGroupCols,AttrNumber*grpColIdx,Oid*grpOperators,
63+
List*groupingSets,List*chain,
64+
doubledNumGroups,Plan*lefttree);
65+
externLimit*make_limit(Plan*lefttree,Node*limitOffset,Node*limitCount);
5866

5967
/*
6068
* prototypes for plan/initsplan.c

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp