diff --git a/contrib/postgres_fdw/expected/postgres_fdw.out b/contrib/postgres_fdw/expected/postgres_fdw.out
index e034b030f1..b9ef6aea64 100644
--- a/contrib/postgres_fdw/expected/postgres_fdw.out
+++ b/contrib/postgres_fdw/expected/postgres_fdw.out
@@ -665,7 +665,7 @@ EXPLAIN (VERBOSE, COSTS OFF) SELECT * FROM ft1 t1 WHERE c1 = ANY(ARRAY[c2, 1, c1
    Remote SQL: SELECT "C 1", c2, c3, c4, c5, c6, c7, c8 FROM "S 1"."T 1" WHERE (("C 1" = ANY (ARRAY[c2, 1, ("C 1" + 0)])))
 (3 rows)
 
-EXPLAIN (VERBOSE, COSTS OFF) SELECT * FROM ft1 t1 WHERE c1 = (ARRAY[c1,c2,3])[1]; -- ArrayRef
+EXPLAIN (VERBOSE, COSTS OFF) SELECT * FROM ft1 t1 WHERE c1 = (ARRAY[c1,c2,3])[1]; -- SubscriptingRef
                                                       QUERY PLAN                                                      
 ----------------------------------------------------------------------------------------------------------------------
  Foreign Scan on public.ft1 t1
diff --git a/contrib/postgres_fdw/sql/postgres_fdw.sql b/contrib/postgres_fdw/sql/postgres_fdw.sql
index 73852f1ae6..82e11eaf52 100644
--- a/contrib/postgres_fdw/sql/postgres_fdw.sql
+++ b/contrib/postgres_fdw/sql/postgres_fdw.sql
@@ -297,7 +297,7 @@ EXPLAIN (VERBOSE, COSTS OFF) SELECT * FROM ft1 t1 WHERE c1 = -c1;          -- Op
 EXPLAIN (VERBOSE, COSTS OFF) SELECT * FROM ft1 t1 WHERE 1 = c1!;           -- OpExpr(r)
 EXPLAIN (VERBOSE, COSTS OFF) SELECT * FROM ft1 t1 WHERE (c1 IS NOT NULL) IS DISTINCT FROM (c1 IS NOT NULL); -- DistinctExpr
 EXPLAIN (VERBOSE, COSTS OFF) SELECT * FROM ft1 t1 WHERE c1 = ANY(ARRAY[c2, 1, c1 + 0]); -- ScalarArrayOpExpr
-EXPLAIN (VERBOSE, COSTS OFF) SELECT * FROM ft1 t1 WHERE c1 = (ARRAY[c1,c2,3])[1]; -- ArrayRef
+EXPLAIN (VERBOSE, COSTS OFF) SELECT * FROM ft1 t1 WHERE c1 = (ARRAY[c1,c2,3])[1]; -- SubscriptingRef
 EXPLAIN (VERBOSE, COSTS OFF) SELECT * FROM ft1 t1 WHERE c6 = E'foo''s\\bar';  -- check special chars
 EXPLAIN (VERBOSE, COSTS OFF) SELECT * FROM ft1 t1 WHERE c8 = 'foo';  -- can't be sent to remote
 -- parameterized remote path for foreign table
diff --git a/src/backend/executor/execExpr.c b/src/backend/executor/execExpr.c
index 0a7b2b8f47..369b9fc8c7 100644
--- a/src/backend/executor/execExpr.c
+++ b/src/backend/executor/execExpr.c
@@ -1200,7 +1200,7 @@ ExecInitExprRec(Expr *node, ExprState *state,
 					 * field's values[]/nulls[] entries as both the caseval
 					 * source and the result address for this subexpression.
 					 * That's okay only because (1) both FieldStore and
-					 * ArrayRef evaluate their arg or refexpr inputs first,
+					 * SubscriptingRef evaluate their arg or refexpr inputs first,
 					 * and (2) any such CaseTestExpr is directly the arg or
 					 * refexpr input.  So any read of the caseval will occur
 					 * before there's a chance to overwrite it.  Also, if
diff --git a/src/backend/optimizer/util/clauses.c b/src/backend/optimizer/util/clauses.c
index 501b0e9e2d..8808da7679 100644
--- a/src/backend/optimizer/util/clauses.c
+++ b/src/backend/optimizer/util/clauses.c
@@ -3409,8 +3409,8 @@ eval_const_expressions_mutator(Node *node,
 			{
 				/*
 				 * This case could be folded into the generic handling used
-				 * for ArrayRef etc.  But because the simplification logic is
-				 * so trivial, applying evaluate_expr() to perform it would be
+				 * for SubscriptingRef etc.  But because the simplification logic
+				 * is so trivial, applying evaluate_expr() to perform it would be
 				 * a heavy overhead.  BooleanTest is probably common enough to
 				 * justify keeping this bespoke implementation.
 				 */
diff --git a/src/backend/parser/parse_target.c b/src/backend/parser/parse_target.c
index 0e9598ebfe..9bd7e14cd3 100644
--- a/src/backend/parser/parse_target.c
+++ b/src/backend/parser/parse_target.c
@@ -695,7 +695,7 @@ transformAssignmentIndirection(ParseState *pstate,
 		/*
 		 * Set up a substitution.  We abuse CaseTestExpr for this.  It's safe
 		 * to do so because the only nodes that will be above the CaseTestExpr
-		 * in the finished expression will be FieldStore and ArrayRef nodes.
+		 * in the finished expression will be FieldStore and SubscriptingRef nodes.
 		 * (There could be other stuff in the tree, but it will be within
 		 * other child fields of those node types.)
 		 */
diff --git a/src/backend/rewrite/rewriteHandler.c b/src/backend/rewrite/rewriteHandler.c
index 39080776b0..ddcbaf3811 100644
--- a/src/backend/rewrite/rewriteHandler.c
+++ b/src/backend/rewrite/rewriteHandler.c
@@ -980,9 +980,9 @@ process_matched_tle(TargetEntry *src_tle,
 	 *
 	 * As a further complication, the destination column might be a domain,
 	 * resulting in each assignment containing a CoerceToDomain node over a
-	 * FieldStore or ArrayRef.  These should have matching target domains,
+	 * FieldStore or SubscriptingRef.  These should have matching target domains,
 	 * so we strip them and reconstitute a single CoerceToDomain over the
-	 * combined FieldStore/ArrayRef nodes.  (Notice that this has the result
+	 * combined FieldStore/SubscriptingRef nodes.  (Notice that this has the result
 	 * that the domain's checks are applied only after we do all the field or
 	 * element updates, not after each one.  This is arguably desirable.)
 	 *----------
diff --git a/src/include/nodes/primnodes.h b/src/include/nodes/primnodes.h
index f9b1cf2df7..2805e803d6 100644
--- a/src/include/nodes/primnodes.h
+++ b/src/include/nodes/primnodes.h
@@ -942,7 +942,7 @@ typedef struct CaseWhen
  * We also abuse this node type for some other purposes, including:
  *	* Placeholder for the current array element value in ArrayCoerceExpr;
  *	  see build_coercion_expression().
- *	* Nested FieldStore/ArrayRef assignment expressions in INSERT/UPDATE;
+ *	* Nested FieldStore/SubscriptingRef assignment expressions in INSERT/UPDATE;
  *	  see transformAssignmentIndirection().
  *
  * The uses in CaseExpr and ArrayCoerceExpr are safe only to the extent that
@@ -952,7 +952,7 @@ typedef struct CaseWhen
  * break it.
  *
  * The nested-assignment-expression case is safe because the only node types
- * that can be above such CaseTestExprs are FieldStore and ArrayRef.
+ * that can be above such CaseTestExprs are FieldStore and SubscriptingRef.
  */
 typedef struct CaseTestExpr
 {
diff --git a/src/tools/pgindent/typedefs.list b/src/tools/pgindent/typedefs.list
index c6050a3f77..813f20a7f5 100644
--- a/src/tools/pgindent/typedefs.list
+++ b/src/tools/pgindent/typedefs.list
@@ -127,8 +127,6 @@ ArrayIterator
 ArrayMapState
 ArrayMetaState
 ArrayParseState
-ArrayRef
-ArrayRefState
 ArrayType
 AsyncQueueControl
 AsyncQueueEntry
@@ -2276,6 +2274,8 @@ SubXactEvent
 SubqueryScan
 SubqueryScanPath
 SubqueryScanState
+SubscriptingRef
+SubscriptingRefState
 Subscription
 SubscriptionInfo
 SubscriptionRelState
