postgres.git / summary / log / commit / refs
commit 9f65aaa408f60081a057f559b717100b55511698
Author: Michael Paquier <michael@paquier.xyz>
Date: Sun Sep 18 06:33:16 2022 +0000
First released in: 16.0
Remove unused argument "isSlice" from transformAssignmentSubscripts()
Since c7aba7c, the transform method used during parse analysis of a
subcripting construct has moved from transformAssignmentSubscripts() to
the per-type transform method (arrays or arbitrary types) the step that
checks for slicing support, but transformAssignmentSubscripts() has kept
traces of it. Removing it simplifies the code, so let's clean up all
that.
Author: Zhang Mingli
Reviewed-by: Richard Guo
Discussion: https://postgr.es/m/0d7041ac-c704-48ad-86fd-e05feddf08ed@Spark
src/backend/parser/parse_target.c | 9 ---------
1 file changed, 9 deletions(-)
diff --git a/src/backend/parser/parse_target.c b/src/backend/parser/parse_target.c
index 4e1593d9008..bd8057bc3e7 100644
--- a/src/backend/parser/parse_target.c
+++ b/src/backend/parser/parse_target.c
@@ -41,7 +41,6 @@ static Node *transformAssignmentSubscripts(ParseState *pstate,
int32 targetTypMod,
Oid targetCollation,
List *subscripts,
- bool isSlice,
List *indirection,
ListCell *next_indirection,
Node *rhs,
@@ -697,7 +696,6 @@ transformAssignmentIndirection(ParseState *pstate,
{
Node *result;
List *subscripts = NIL;
- bool isSlice = false;
ListCell *i;
if (indirection_cell && !basenode)
@@ -727,11 +725,7 @@ transformAssignmentIndirection(ParseState *pstate,
Node *n = lfirst(i);
if (IsA(n, A_Indices))
- {
subscripts = lappend(subscripts, n);
- if (((A_Indices *) n)->is_slice)
- isSlice = true;
- }
else if (IsA(n, A_Star))
{
ereport(ERROR,
@@ -763,7 +757,6 @@ transformAssignmentIndirection(ParseState *pstate,
targetTypMod,
targetCollation,
subscripts,
- isSlice,
indirection,
i,
rhs,
@@ -853,7 +846,6 @@ transformAssignmentIndirection(ParseState *pstate,
targetTypMod,
targetCollation,
subscripts,
- isSlice,
indirection,
NULL,
rhs,
@@ -907,7 +899,6 @@ transformAssignmentSubscripts(ParseState *pstate,
int32 targetTypMod,
Oid targetCollation,
List *subscripts,
- bool isSlice,
List *indirection,
ListCell *next_indirection,
Node *rhs,
[parent: 035ce1feb2ed]