From d984108d931ea74b1435620edb15f087f0c257c2 Mon Sep 17 00:00:00 2001 From: Joel Brobecker Date: Wed, 23 Nov 2011 19:54:08 +0000 Subject: [PATCH] fix -Wshadow warning inside ada-lang.c:assign_aggregate gdb/ChangeLog: From Andrey Smirnov : * ada-lang.c (assign_aggregate): Remove declaration of local variable `i' which is shadowing another variable with the same name declared in the outer scope. --- gdb/ChangeLog | 6 ++++++ gdb/ada-lang.c | 2 -- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 3bb6d51d05..ea8fb66e42 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,9 @@ +2011-11-23 Andrey Smirnov + + * ada-lang.c (assign_aggregate): Remove declaration of local + variable `i' which is shadowing another variable with the same + name declared in the outer scope. + 2011-11-23 Joel Brobecker * ada-lang.c (get_base_type): Renames base_type. Adjust all diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c index 66766850f7..48073fb3d0 100644 --- a/gdb/ada-lang.c +++ b/gdb/ada-lang.c @@ -8665,8 +8665,6 @@ assign_aggregate (struct value *container, *pos += 3; if (noside != EVAL_NORMAL) { - int i; - for (i = 0; i < n; i += 1) ada_evaluate_subexp (NULL, exp, pos, noside); return container; -- 2.34.1