diff options
author | Tom Tromey <tromey@redhat.com> | 2013-07-01 19:50:11 +0000 |
---|---|---|
committer | Tom Tromey <tromey@redhat.com> | 2013-07-01 19:50:11 +0000 |
commit | 44d100c3b90473c1995acaf74ee3a424aedb9701 (patch) | |
tree | fa7e15fe08c402ebed992183dce7380420e44314 /gdb/dsrec.c | |
parent | 2945b8076ce1f332cd9b9ddb7b8784283132d39b (diff) | |
download | gdb-44d100c3b90473c1995acaf74ee3a424aedb9701.zip gdb-44d100c3b90473c1995acaf74ee3a424aedb9701.tar.gz gdb-44d100c3b90473c1995acaf74ee3a424aedb9701.tar.bz2 |
add -Wold-style-declaration
This adds -Wold-style-declaration to gdb's list of warnings.
It turns out that a few places use "const static" rather than
"static const". The former is deprecated according to the C standard.
Tested by rebuilding with --enable-targets=all on x86-64 Fedora 18.
* configure.ac (build_warnings): Add -Wold-style-declaration.
* configure: Rebuild.
* dsrec.c (make_srec): Use "static const", not "const static".
* h8300-tdep.c (h8300_breakpoint_from_pc): Use "static const",
not "const static".
* mi/mi-parse.c (mi_no_values, mi_simple_values, mi_all_values):
Use "static const", not "const static".
* mn10300-tdep.c (mn10300_breakpoint_from_pc): Use "static const",
not "const static".
* moxie-tdep.c (moxie_breakpoint_from_pc): Use "static const",
not "const static".
* rs6000-tdep.c (rs6000_breakpoint_from_pc): Use "static const",
not "const static".
* v850-tdep.c (v850_breakpoint_from_pc): Use "static const",
not "const static".
(v850_dbtrap_breakpoint_from_pc): Likewise.
* xstormy16-tdep.c (xstormy16_breakpoint_from_pc): Use "static const",
not "const static".
Diffstat (limited to 'gdb/dsrec.c')
-rw-r--r-- | gdb/dsrec.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/gdb/dsrec.c b/gdb/dsrec.c index 04dd9c6..bc47f84 100644 --- a/gdb/dsrec.c +++ b/gdb/dsrec.c @@ -226,10 +226,10 @@ make_srec (char *srec, CORE_ADDR targ_addr, bfd *abfd, asection *sect, { unsigned char checksum; int tmp; - const static char hextab[] = "0123456789ABCDEF"; - const static char data_code_table[] = "123"; - const static char term_code_table[] = "987"; - const static char header_code_table[] = "000"; + static const char hextab[] = "0123456789ABCDEF"; + static const char data_code_table[] = "123"; + static const char term_code_table[] = "987"; + static const char header_code_table[] = "000"; char const *code_table; int addr_size; int payload_size; |