mirror of
https://github.com/postgres/postgres.git
synced 2025-09-03 15:22:11 +03:00
Stop including parsenodes.h in plannodes.h
I added it by mistake in commit7103ebb7aa
. To clean up, struct MergeAction needs to be moved to primnodes.h from parsenodes.h. (This forces us to also move OverridingKind to primnodes.h). Having to add parsenodes.h to bootstrap.h as fallout is a bit surprising, since nothing nominally needs it there. However, per comments in bootscanner.l, it is needed so that YYSTYPE can be declared. I think this only started with commitdac048f71e
, but I didn't actually verify that. In passing, stop including parsenodes.h in tcopprot.h. Nothing needs it there. Per discussion on a patch by Ashutosh Bapat. Reviewed-by: Tom Lane <tgl@sss.pgh.pa.us> Discussion: https://postgr.es/m/202311071106.6y7b2ascqjlz@alvherre.pgsql
This commit is contained in:
@@ -13,6 +13,7 @@
|
|||||||
*/
|
*/
|
||||||
#include "postgres.h"
|
#include "postgres.h"
|
||||||
|
|
||||||
|
#include "nodes/parsenodes.h"
|
||||||
#include "nodes/supportnodes.h"
|
#include "nodes/supportnodes.h"
|
||||||
#include "utils/builtins.h"
|
#include "utils/builtins.h"
|
||||||
#include "windowapi.h"
|
#include "windowapi.h"
|
||||||
|
@@ -15,6 +15,7 @@
|
|||||||
#define BOOTSTRAP_H
|
#define BOOTSTRAP_H
|
||||||
|
|
||||||
#include "nodes/execnodes.h"
|
#include "nodes/execnodes.h"
|
||||||
|
#include "nodes/parsenodes.h"
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@@ -30,13 +30,6 @@
|
|||||||
#include "partitioning/partdefs.h"
|
#include "partitioning/partdefs.h"
|
||||||
|
|
||||||
|
|
||||||
typedef enum OverridingKind
|
|
||||||
{
|
|
||||||
OVERRIDING_NOT_SET = 0,
|
|
||||||
OVERRIDING_USER_VALUE,
|
|
||||||
OVERRIDING_SYSTEM_VALUE,
|
|
||||||
} OverridingKind;
|
|
||||||
|
|
||||||
/* Possible sources of a Query */
|
/* Possible sources of a Query */
|
||||||
typedef enum QuerySource
|
typedef enum QuerySource
|
||||||
{
|
{
|
||||||
@@ -1681,23 +1674,6 @@ typedef struct MergeWhenClause
|
|||||||
List *values; /* VALUES to INSERT, or NULL */
|
List *values; /* VALUES to INSERT, or NULL */
|
||||||
} MergeWhenClause;
|
} MergeWhenClause;
|
||||||
|
|
||||||
/*
|
|
||||||
* MergeAction -
|
|
||||||
* Transformed representation of a WHEN clause in a MERGE statement
|
|
||||||
*/
|
|
||||||
typedef struct MergeAction
|
|
||||||
{
|
|
||||||
NodeTag type;
|
|
||||||
bool matched; /* true=MATCHED, false=NOT MATCHED */
|
|
||||||
CmdType commandType; /* INSERT/UPDATE/DELETE/DO NOTHING */
|
|
||||||
/* OVERRIDING clause */
|
|
||||||
OverridingKind override pg_node_attr(query_jumble_ignore);
|
|
||||||
Node *qual; /* transformed WHEN conditions */
|
|
||||||
List *targetList; /* the target list (of TargetEntry) */
|
|
||||||
/* target attribute numbers of an UPDATE */
|
|
||||||
List *updateColnos pg_node_attr(query_jumble_ignore);
|
|
||||||
} MergeAction;
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* TriggerTransition -
|
* TriggerTransition -
|
||||||
* representation of transition row or table naming clause
|
* representation of transition row or table naming clause
|
||||||
|
@@ -20,7 +20,6 @@
|
|||||||
#include "lib/stringinfo.h"
|
#include "lib/stringinfo.h"
|
||||||
#include "nodes/bitmapset.h"
|
#include "nodes/bitmapset.h"
|
||||||
#include "nodes/lockoptions.h"
|
#include "nodes/lockoptions.h"
|
||||||
#include "nodes/parsenodes.h"
|
|
||||||
#include "nodes/primnodes.h"
|
#include "nodes/primnodes.h"
|
||||||
|
|
||||||
|
|
||||||
|
@@ -22,6 +22,14 @@
|
|||||||
#include "nodes/pg_list.h"
|
#include "nodes/pg_list.h"
|
||||||
|
|
||||||
|
|
||||||
|
typedef enum OverridingKind
|
||||||
|
{
|
||||||
|
OVERRIDING_NOT_SET = 0,
|
||||||
|
OVERRIDING_USER_VALUE,
|
||||||
|
OVERRIDING_SYSTEM_VALUE,
|
||||||
|
} OverridingKind;
|
||||||
|
|
||||||
|
|
||||||
/* ----------------------------------------------------------------
|
/* ----------------------------------------------------------------
|
||||||
* node definitions
|
* node definitions
|
||||||
* ----------------------------------------------------------------
|
* ----------------------------------------------------------------
|
||||||
@@ -1718,6 +1726,25 @@ typedef struct BooleanTest
|
|||||||
int location; /* token location, or -1 if unknown */
|
int location; /* token location, or -1 if unknown */
|
||||||
} BooleanTest;
|
} BooleanTest;
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
* MergeAction
|
||||||
|
*
|
||||||
|
* Transformed representation of a WHEN clause in a MERGE statement
|
||||||
|
*/
|
||||||
|
typedef struct MergeAction
|
||||||
|
{
|
||||||
|
NodeTag type;
|
||||||
|
bool matched; /* true=MATCHED, false=NOT MATCHED */
|
||||||
|
CmdType commandType; /* INSERT/UPDATE/DELETE/DO NOTHING */
|
||||||
|
/* OVERRIDING clause */
|
||||||
|
OverridingKind override pg_node_attr(query_jumble_ignore);
|
||||||
|
Node *qual; /* transformed WHEN conditions */
|
||||||
|
List *targetList; /* the target list (of TargetEntry) */
|
||||||
|
/* target attribute numbers of an UPDATE */
|
||||||
|
List *updateColnos pg_node_attr(query_jumble_ignore);
|
||||||
|
} MergeAction;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* CoerceToDomain
|
* CoerceToDomain
|
||||||
*
|
*
|
||||||
|
@@ -15,7 +15,6 @@
|
|||||||
#define TCOPPROT_H
|
#define TCOPPROT_H
|
||||||
|
|
||||||
#include "nodes/params.h"
|
#include "nodes/params.h"
|
||||||
#include "nodes/parsenodes.h"
|
|
||||||
#include "nodes/plannodes.h"
|
#include "nodes/plannodes.h"
|
||||||
#include "storage/procsignal.h"
|
#include "storage/procsignal.h"
|
||||||
#include "utils/guc.h"
|
#include "utils/guc.h"
|
||||||
|
Reference in New Issue
Block a user