This is the mail archive of the
gdb-testers@sourceware.org
mailing list for the GDB project.
[binutils-gdb] S12Z/opcodes: Correct a `reg' global shadowing error for pre-4.8 GCC
- From: sergiodj+buildbot at sergiodj dot net
- To: gdb-testers at sourceware dot org
- Date: Mon, 09 Jul 2018 13:40:53 -0400
- Subject: [binutils-gdb] S12Z/opcodes: Correct a `reg' global shadowing error for pre-4.8 GCC
*** TEST RESULTS FOR COMMIT 9dcb0ba4457b8845fb704635e824471bf1faf092 ***
Author: Maciej W. Rozycki <macro@mips.com>
Branch: master
Commit: 9dcb0ba4457b8845fb704635e824471bf1faf092
S12Z/opcodes: Correct a `reg' global shadowing error for pre-4.8 GCC
Remove `-Wshadow' compilation errors:
cc1: warnings being treated as errors
.../opcodes/s12z-dis.c: In function 'lea_reg_xys_opr':
.../opcodes/s12z-dis.c:814: error: declaration of 'reg' shadows a global declaration
.../opcodes/s12z-dis.c:783: error: shadowed declaration is here
.../opcodes/s12z-dis.c: In function 'lea_reg_xys':
.../opcodes/s12z-dis.c:843: error: declaration of 'reg' shadows a global declaration
.../opcodes/s12z-dis.c:783: error: shadowed declaration is here
.../opcodes/s12z-dis.c: In function 'print_insn_loop_primitive':
.../opcodes/s12z-dis.c:2206: error: declaration of 'reg' shadows a global declaration
.../opcodes/s12z-dis.c:783: error: shadowed declaration is here
which for versions of GCC before 4.8 prevent support for S12Z targets
from being built. See also GCC PR c/53066.
opcodes/
* s12z-dis.c (lea_reg_xys_opr): Rename `reg' local variable to
`reg_xys'.
(lea_reg_xys): Likewise.
(print_insn_loop_primitive): Rename `reg' local variable to
`reg_dxy'.