get_symbol_name () returns a char * in a out arg, which means we need to cast
to assign a literal to the variable passed to get_symbol_name (). It seems
like better APIs than get_symbol_name () could be provided, but that seems like
a fair amount of work so just casting seems to be the betterthing to do for
now.
gas/ChangeLog:
2016-03-31 Trevor Saunders <tbsaunde+binutils@tbsaunde.org>
* config/tc-ia64.c (md_assemble): Add temporary variable to pass to
get_symbol_name ().
* config/tc-sparc.c (s_register): Cast a literal to char * in
assignment.
+2016-03-31 Trevor Saunders <tbsaunde+binutils@tbsaunde.org>
+
+ * config/tc-ia64.c (md_assemble): Add temporary variable to pass to
+ get_symbol_name ().
+ * config/tc-sparc.c (s_register): Cast a literal to char * in
+ assignment.
+
2016-03-31 Trevor Saunders <tbsaunde+binutils@tbsaunde.org>
* config/tc-i960.c (parse_expr): Cast to char * when assigning to
void
md_assemble (char *str)
{
- char *saved_input_line_pointer, *mnemonic;
+ char *saved_input_line_pointer, *temp;
+ const char *mnemonic;
const struct pseudo_opcode *pdesc;
struct ia64_opcode *idesc;
unsigned char qp_regno;
/* extract the opcode (mnemonic): */
- ch = get_symbol_name (&mnemonic);
+ ch = get_symbol_name (&temp);
+ mnemonic = temp;
pdesc = (struct pseudo_opcode *) hash_find (md.pseudo_hash, mnemonic);
if (pdesc)
{
if (regname[0] == 'i')
regname = NULL;
else
- regname = "";
+ regname = (char *) "";
}
else
{