This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
[PATCH 046/238] [index] dcache.c: -Wshadow fix
- From: Andrey Smirnov <andrew dot smirnov at gmail dot com>
- To: gdb-patches at sourceware dot org
- Cc: Andrey Smirnov <andrew dot smirnov at gmail dot com>
- Date: Mon, 12 Dec 2011 19:38:49 -0800
- Subject: [PATCH 046/238] [index] dcache.c: -Wshadow fix
- References: <1323747545-29987-1-git-send-email-andrew.smirnov@gmail.com>
To ChangeLog:
* dcache.c (dcache_print_line): Rename `index' to `idx'(-Wshadow).
---
gdb/dcache.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/gdb/dcache.c b/gdb/dcache.c
index bcc7bf4..de0ca38 100644
--- a/gdb/dcache.c
+++ b/gdb/dcache.c
@@ -559,7 +559,7 @@ dcache_update (DCACHE *dcache, CORE_ADDR memaddr, gdb_byte *myaddr, int len)
}
static void
-dcache_print_line (int index)
+dcache_print_line (int idx)
{
splay_tree_node n;
struct dcache_block *db;
@@ -573,7 +573,7 @@ dcache_print_line (int index)
n = splay_tree_min (last_cache->tree);
- for (i = index; i > 0; --i)
+ for (i = idx; i > 0; --i)
{
if (!n)
break;
@@ -589,7 +589,7 @@ dcache_print_line (int index)
db = (struct dcache_block *) n->value;
printf_filtered (_("Line %d: address %s [%d hits]\n"),
- index, paddress (target_gdbarch, db->addr), db->refs);
+ idx, paddress (target_gdbarch, db->addr), db->refs);
for (j = 0; j < last_cache->line_size; j++)
{
--
1.7.5.4