From 3e0fff2e6888e39b0ad5cdfdb78bc1c2bb2b22c9 Mon Sep 17 00:00:00 2001 From: David Rowley Date: Fri, 26 Aug 2022 02:35:40 +1200 Subject: More -Wshadow=compatible-local warning fixes In a similar effort to f01592f91, here we're targetting fixing the warnings where we've deemed the shadowing variable to serve a close enough purpose to the shadowed variable just to reuse the shadowed version and not declare the shadowing variable at all. By my count, this takes the warning count from 106 down to 71. Author: Justin Pryzby Discussion: https://postgr.es/m/20220825020839.GT2342@telsasoft.com --- src/backend/utils/adt/ruleutils.c | 3 --- 1 file changed, 3 deletions(-) (limited to 'src/backend/utils/adt/ruleutils.c') diff --git a/src/backend/utils/adt/ruleutils.c b/src/backend/utils/adt/ruleutils.c index 8280711f7ef..9959f6910e9 100644 --- a/src/backend/utils/adt/ruleutils.c +++ b/src/backend/utils/adt/ruleutils.c @@ -1303,7 +1303,6 @@ pg_get_indexdef_worker(Oid indexrelid, int colno, if (!heap_attisnull(ht_idx, Anum_pg_index_indexprs, NULL)) { Datum exprsDatum; - bool isnull; char *exprsString; exprsDatum = SysCacheGetAttr(INDEXRELID, ht_idx, @@ -1500,7 +1499,6 @@ pg_get_indexdef_worker(Oid indexrelid, int colno, { Node *node; Datum predDatum; - bool isnull; char *predString; /* Convert text string to node tree */ @@ -1945,7 +1943,6 @@ pg_get_partkeydef_worker(Oid relid, int prettyFlags, if (!heap_attisnull(tuple, Anum_pg_partitioned_table_partexprs, NULL)) { Datum exprsDatum; - bool isnull; char *exprsString; exprsDatum = SysCacheGetAttr(PARTRELID, tuple, -- cgit v1.2.3