aboutsummaryrefslogtreecommitdiff
path: root/gas
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2021-07-02 17:27:31 +0930
committerAlan Modra <amodra@gmail.com>2021-07-02 20:48:55 +0930
commit62194b631d00112bac1f8856d3259d774df4c15e (patch)
treecd7385f4fdfbd31d5773180313cea95c3b340bdf /gas
parentaf82b082c27eeefa261753e746fd002cc528cd1f (diff)
downloadgdb-62194b631d00112bac1f8856d3259d774df4c15e.zip
gdb-62194b631d00112bac1f8856d3259d774df4c15e.tar.gz
gdb-62194b631d00112bac1f8856d3259d774df4c15e.tar.bz2
Re: Fix minor NDS32 renaming snafu
Some extern declarations differ in constnes to their definitions too. Let's make sure this sort of thing doesn't happen again, but putting the externs in a header where they belong. gas/ * config/tc-nds32.c (nds32_keyword_gpr): Don't declare. (md_begin): Constify k. opcodes/ * nds32-dis.c (nds32_find_reg_keyword): Constify arg and return. (nds32_parse_audio_ext, nds32_parse_opcode): Constify psys_reg. (nds32_field_table, nds32_opcode_table, nds32_keyword_table), (nds32_opcodes, nds32_operand_fields, nds32_keywords), (nds32_keyword_gpr): Move declarations to.. * nds32-asm.h: ..here, constifying to match definitions.
Diffstat (limited to 'gas')
-rw-r--r--gas/ChangeLog5
-rw-r--r--gas/config/tc-nds32.c3
2 files changed, 6 insertions, 2 deletions
diff --git a/gas/ChangeLog b/gas/ChangeLog
index c154835..2e7a1ca 100644
--- a/gas/ChangeLog
+++ b/gas/ChangeLog
@@ -1,3 +1,8 @@
+2021-07-02 Alan Modra <amodra@gmail.com>
+
+ * config/tc-nds32.c (nds32_keyword_gpr): Don't declare.
+ (md_begin): Constify k.
+
2021-07-02 Nick Clifton <nickc@redhat.com>
* config/tc-nds32.c: Change all references of keyword_gpr to
diff --git a/gas/config/tc-nds32.c b/gas/config/tc-nds32.c
index 04ae689..4ff667c 100644
--- a/gas/config/tc-nds32.c
+++ b/gas/config/tc-nds32.c
@@ -97,7 +97,6 @@ static int optimize_for_space = 0;
static int label_exist = 0;
/* Flag to save state in omit_fp region. */
static int in_omit_fp = 0;
-extern struct nds32_keyword nds32_keyword_gpr[];
/* Tag there is relax relocation having to link. */
static bool relaxing = false;
/* ICT model. */
@@ -4601,7 +4600,7 @@ nds32_asm_parse_operand (struct nds32_asm_desc *pdesc ATTRIBUTE_UNUSED,
void
md_begin (void)
{
- struct nds32_keyword *k;
+ const struct nds32_keyword *k;
relax_info_t *relax_info;
int flags = 0;