This is an automated email from the ASF dual-hosted git repository.
mtaha pushed a commit to branch PG11
in repository https://gitbox.apache.org/repos/asf/age.git
The following commit(s) were added to refs/heads/PG11 by this push:
new 113093de Clean up #included files in parser directory (#1465) (#1472)
113093de is described below
commit 113093de6beed8358315f9c1ff2dc8f371fbd09d
Author: John Gemignani <[email protected]>
AuthorDate: Sun Dec 31 00:52:45 2023 -0800
Clean up #included files in parser directory (#1465) (#1472)
Cleaned up #included files in the .c files in the parser directory.
Additionally, fixed one that was at the backend root.
modified: src/backend/age.c
modified: src/backend/parser/cypher_analyze.c
modified: src/backend/parser/cypher_clause.c
modified: src/backend/parser/cypher_expr.c
modified: src/backend/parser/cypher_gram.y
modified: src/backend/parser/cypher_item.c
modified: src/backend/parser/cypher_keywords.c
modified: src/backend/parser/cypher_parse_node.c
modified: src/backend/parser/cypher_parser.c
Added in #include "parser/parse_relation.h" into cypher_clause due
to differences between PostgreSQL 16 and 15.
Resolved -
Conflicts:
src/backend/parser/cypher_analyze.c
src/backend/parser/cypher_clause.c
src/backend/parser/cypher_expr.c
src/backend/parser/cypher_parser.c
---
src/backend/age.c | 4 ----
src/backend/parser/cypher_analyze.c | 8 --------
src/backend/parser/cypher_clause.c | 16 +---------------
src/backend/parser/cypher_expr.c | 13 +------------
src/backend/parser/cypher_gram.y | 8 --------
src/backend/parser/cypher_item.c | 7 -------
src/backend/parser/cypher_keywords.c | 6 +-----
src/backend/parser/cypher_parse_node.c | 2 --
src/backend/parser/cypher_parser.c | 3 ---
9 files changed, 3 insertions(+), 64 deletions(-)
diff --git a/src/backend/age.c b/src/backend/age.c
index a512f188..2c016b02 100644
--- a/src/backend/age.c
+++ b/src/backend/age.c
@@ -17,10 +17,6 @@
* under the License.
*/
-#include "postgres.h"
-
-#include "fmgr.h"
-
#include "catalog/ag_catalog.h"
#include "nodes/ag_nodes.h"
#include "optimizer/cypher_paths.h"
diff --git a/src/backend/parser/cypher_analyze.c
b/src/backend/parser/cypher_analyze.c
index 890fbaae..57dd06ab 100644
--- a/src/backend/parser/cypher_analyze.c
+++ b/src/backend/parser/cypher_analyze.c
@@ -22,28 +22,20 @@
#include "catalog/pg_type_d.h"
#include "nodes/makefuncs.h"
#include "nodes/nodeFuncs.h"
-#include "nodes/nodes.h"
-#include "nodes/parsenodes.h"
-#include "nodes/pg_list.h"
-#include "nodes/primnodes.h"
#include "parser/analyze.h"
#include "parser/parse_coerce.h"
#include "parser/parse_collate.h"
-#include "parser/parse_node.h"
#include "parser/parse_relation.h"
#include "parser/parse_target.h"
#include "parser/parsetree.h"
#include "utils/builtins.h"
#include "catalog/ag_graph.h"
-#include "nodes/ag_nodes.h"
#include "parser/cypher_analyze.h"
#include "parser/cypher_clause.h"
-#include "parser/cypher_parse_node.h"
#include "parser/cypher_parser.h"
#include "utils/ag_func.h"
#include "utils/age_session_info.h"
-#include "utils/agtype.h"
/*
* extra_node is a global variable to this source to store, at the moment, the
diff --git a/src/backend/parser/cypher_clause.c
b/src/backend/parser/cypher_clause.c
index 90f5547b..e74dcb1e 100644
--- a/src/backend/parser/cypher_clause.c
+++ b/src/backend/parser/cypher_clause.c
@@ -24,46 +24,32 @@
#include "postgres.h"
-#include "access/sysattr.h"
#include "catalog/pg_type_d.h"
#include "miscadmin.h"
-#include "nodes/makefuncs.h"
#include "nodes/nodeFuncs.h"
-#include "nodes/nodes.h"
-#include "nodes/parsenodes.h"
-#include "nodes/pg_list.h"
-#include "nodes/primnodes.h"
#include "optimizer/var.h"
+#include "utils/rel.h"
#include "parser/parse_clause.h"
#include "parser/parse_coerce.h"
#include "parser/parse_collate.h"
#include "parser/parse_expr.h"
#include "parser/parse_func.h"
-#include "parser/parse_node.h"
#include "parser/parse_oper.h"
#include "parser/parse_relation.h"
#include "parser/parse_target.h"
#include "parser/parsetree.h"
#include "rewrite/rewriteHandler.h"
-#include "utils/typcache.h"
-#include "utils/lsyscache.h"
-#include "utils/rel.h"
#include "catalog/ag_graph.h"
#include "catalog/ag_label.h"
#include "commands/label_commands.h"
-#include "nodes/ag_nodes.h"
-#include "nodes/cypher_nodes.h"
#include "parser/cypher_clause.h"
#include "parser/cypher_expr.h"
#include "parser/cypher_item.h"
#include "parser/cypher_parse_agg.h"
-#include "parser/cypher_parse_node.h"
#include "parser/cypher_transform_entity.h"
#include "utils/ag_cache.h"
#include "utils/ag_func.h"
-#include "utils/agtype.h"
-#include "utils/graphid.h"
#include "utils/ag_guc.h"
/*
diff --git a/src/backend/parser/cypher_expr.c b/src/backend/parser/cypher_expr.c
index 36e8862c..ec4de38f 100644
--- a/src/backend/parser/cypher_expr.c
+++ b/src/backend/parser/cypher_expr.c
@@ -24,31 +24,20 @@
#include "postgres.h"
-#include "catalog/pg_type.h"
#include "miscadmin.h"
-#include "nodes/makefuncs.h"
+#include "catalog/pg_type_d.h"
#include "nodes/nodeFuncs.h"
-#include "nodes/nodes.h"
-#include "nodes/parsenodes.h"
-#include "nodes/value.h"
-#include "optimizer/tlist.h"
#include "parser/parse_coerce.h"
#include "parser/parse_collate.h"
-#include "parser/parse_expr.h"
#include "parser/parse_func.h"
#include "parser/cypher_clause.h"
-#include "parser/parse_node.h"
#include "parser/parse_oper.h"
#include "parser/parse_relation.h"
#include "utils/builtins.h"
#include "utils/int8.h"
#include "utils/lsyscache.h"
-#include "utils/syscache.h"
-#include "commands/label_commands.h"
-#include "nodes/cypher_nodes.h"
#include "parser/cypher_expr.h"
-#include "parser/cypher_parse_node.h"
#include "parser/cypher_transform_entity.h"
#include "utils/ag_func.h"
#include "utils/agtype.h"
diff --git a/src/backend/parser/cypher_gram.y b/src/backend/parser/cypher_gram.y
index 6f0c0059..79cf628d 100644
--- a/src/backend/parser/cypher_gram.y
+++ b/src/backend/parser/cypher_gram.y
@@ -21,16 +21,8 @@
#include "postgres.h"
#include "nodes/makefuncs.h"
-#include "nodes/nodes.h"
-#include "nodes/parsenodes.h"
-#include "nodes/pg_list.h"
-#include "nodes/primnodes.h"
-#include "nodes/value.h"
#include "parser/parser.h"
-#include "nodes/ag_nodes.h"
-#include "nodes/cypher_nodes.h"
-#include "parser/ag_scanner.h"
#include "parser/cypher_gram.h"
#include "parser/cypher_parse_node.h"
#include "parser/scansup.h"
diff --git a/src/backend/parser/cypher_item.c b/src/backend/parser/cypher_item.c
index 6eabb60e..00dba613 100644
--- a/src/backend/parser/cypher_item.c
+++ b/src/backend/parser/cypher_item.c
@@ -24,19 +24,12 @@
#include "postgres.h"
-#include "access/attnum.h"
#include "nodes/makefuncs.h"
-#include "nodes/nodes.h"
-#include "nodes/parsenodes.h"
-#include "nodes/pg_list.h"
-#include "nodes/primnodes.h"
-#include "parser/parse_node.h"
#include "parser/parse_relation.h"
#include "parser/parse_target.h"
#include "parser/cypher_expr.h"
#include "parser/cypher_item.h"
-#include "parser/cypher_parse_node.h"
static List *ExpandAllTables(ParseState *pstate, int location);
static List *expand_rel_attrs(ParseState *pstate, RangeTblEntry *rte,
diff --git a/src/backend/parser/cypher_keywords.c
b/src/backend/parser/cypher_keywords.c
index 5ed12028..6075030a 100644
--- a/src/backend/parser/cypher_keywords.c
+++ b/src/backend/parser/cypher_keywords.c
@@ -24,12 +24,8 @@
#include "postgres.h"
-#include "access/attnum.h"
-#include "access/htup.h"
-#include "access/tupdesc.h"
-#include "catalog/pg_type.h"
+#include "catalog/pg_type_d.h"
#include "common/keywords.h"
-#include "fmgr.h"
#include "funcapi.h"
#include "parser/cypher_gram.h"
diff --git a/src/backend/parser/cypher_parse_node.c
b/src/backend/parser/cypher_parse_node.c
index 307ad5be..545790d6 100644
--- a/src/backend/parser/cypher_parse_node.c
+++ b/src/backend/parser/cypher_parse_node.c
@@ -25,8 +25,6 @@
#include "postgres.h"
#include "mb/pg_wchar.h"
-#include "nodes/primnodes.h"
-#include "parser/parse_node.h"
#include "parser/cypher_parse_node.h"
diff --git a/src/backend/parser/cypher_parser.c
b/src/backend/parser/cypher_parser.c
index 03afff77..d648c1b0 100644
--- a/src/backend/parser/cypher_parser.c
+++ b/src/backend/parser/cypher_parser.c
@@ -19,11 +19,8 @@
#include "postgres.h"
-#include "common/keywords.h"
-#include "nodes/pg_list.h"
#include "parser/scansup.h"
-#include "parser/ag_scanner.h"
#include "parser/cypher_gram.h"
#include "parser/cypher_keywords.h"
#include "parser/cypher_parser.h"