]> git.ipfire.org Git - thirdparty/gcc.git/commit
Fix -Wshadow warning in libiberty/cp-demangle.c
authormark <mark@138bc75d-0d04-0410-961f-82ee72b054a4>
Sat, 10 Sep 2016 10:37:35 +0000 (10:37 +0000)
committermark <mark@138bc75d-0d04-0410-961f-82ee72b054a4>
Sat, 10 Sep 2016 10:37:35 +0000 (10:37 +0000)
commit6b3f15b8e2ef8e34633b6ee710915cb7191200d6
tree0309089e144cd3b5bf76f5b14e134f0eb129ec0e
parent4b3412be05383c9fda152e2a4d14ac9e3256f61d
Fix -Wshadow warning in libiberty/cp-demangle.c

valgrind contains a copy of the libiberty demangler which gets compiled
with -Wshadow. That shows the following warning:

cp-demangle.c: In function ‘d_substitution’:
cp-demangle.c:3772:35: warning: declaration of ‘c’ shadows a previous local
        struct demangle_component *c;
                                   ^
cp-demangle.c:3708:8: note: shadowed declaration is here
   char c;
        ^

Fix that by renaming the struct demangle_component variable to dc.

libiberty/ChangeLog:

* cp-demangle.c (d_substitution): Change struct demangle_component
variable name from c to dc.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@240068 138bc75d-0d04-0410-961f-82ee72b054a4
libiberty/ChangeLog
libiberty/cp-demangle.c