1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-30 11:03:19 +03:00

Remove unnecessary casts of makeNode() result

makeNode() is already a macro that has the right result pointer type, so
casting it again to the same type is unnecessary.
This commit is contained in:
Peter Eisentraut
2016-12-23 12:00:00 -05:00
parent 3c9d398484
commit 158df30359
4 changed files with 12 additions and 13 deletions

View File

@ -703,7 +703,7 @@ add_with_check_options(Relation rel,
*/
WithCheckOption *wco;
wco = (WithCheckOption *) makeNode(WithCheckOption);
wco = makeNode(WithCheckOption);
wco->kind = kind;
wco->relname = pstrdup(RelationGetRelationName(rel));
wco->polname = NULL;
@ -735,7 +735,7 @@ add_with_check_options(Relation rel,
qual = copyObject(qual);
ChangeVarNodes((Node *) qual, 1, rt_index, 0);
wco = (WithCheckOption *) makeNode(WithCheckOption);
wco = makeNode(WithCheckOption);
wco->kind = kind;
wco->relname = pstrdup(RelationGetRelationName(rel));
wco->polname = pstrdup(policy->policy_name);
@ -755,7 +755,7 @@ add_with_check_options(Relation rel,
*/
WithCheckOption *wco;
wco = (WithCheckOption *) makeNode(WithCheckOption);
wco = makeNode(WithCheckOption);
wco->kind = kind;
wco->relname = pstrdup(RelationGetRelationName(rel));
wco->polname = NULL;