mirror of
https://github.com/postgres/postgres.git
synced 2025-04-25 21:42:33 +03:00
Fix unnecessary casts of copyObject() result
The result is already of the correct type, so these casts don't do anything. Reviewed-by: Nathan Bossart <nathandbossart@gmail.com> Reviewed-by: Tender Wang <tndrwang@gmail.com> Discussion: https://www.postgresql.org/message-id/flat/637eeea8-5663-460b-a114-39572c0f6c6e%40eisentraut.org
This commit is contained in:
parent
eafda78fc4
commit
665785d85f
@ -1169,7 +1169,7 @@ CreateTriggerFiringOn(CreateTrigStmt *stmt, const char *queryString,
|
||||
* Initialize our fabricated parse node by copying the original
|
||||
* one, then resetting fields that we pass separately.
|
||||
*/
|
||||
childStmt = (CreateTrigStmt *) copyObject(stmt);
|
||||
childStmt = copyObject(stmt);
|
||||
childStmt->funcname = NIL;
|
||||
childStmt->whenClause = NULL;
|
||||
|
||||
|
@ -2996,7 +2996,7 @@ expression_tree_mutator_impl(Node *node,
|
||||
case T_SortGroupClause:
|
||||
case T_CTESearchClause:
|
||||
case T_MergeSupportFunc:
|
||||
return (Node *) copyObject(node);
|
||||
return copyObject(node);
|
||||
case T_WithCheckOption:
|
||||
{
|
||||
WithCheckOption *wco = (WithCheckOption *) node;
|
||||
@ -3604,7 +3604,7 @@ expression_tree_mutator_impl(Node *node,
|
||||
break;
|
||||
case T_PartitionPruneStepCombine:
|
||||
/* no expression sub-nodes */
|
||||
return (Node *) copyObject(node);
|
||||
return copyObject(node);
|
||||
case T_JoinExpr:
|
||||
{
|
||||
JoinExpr *join = (JoinExpr *) node;
|
||||
|
@ -1715,7 +1715,7 @@ ReplaceVarsFromTargetList_callback(Var *var,
|
||||
break;
|
||||
|
||||
case REPLACEVARS_CHANGE_VARNO:
|
||||
var = (Var *) copyObject(var);
|
||||
var = copyObject(var);
|
||||
var->varno = rcon->nomatch_varno;
|
||||
/* we leave the syntactic referent alone */
|
||||
return (Node *) var;
|
||||
|
Loading…
x
Reference in New Issue
Block a user