mdebugread.c: Address class -> address class index
This fixes this error in C++ mode:
/home/pedro/gdb/mygit/cxx-convertion/src/gdb/mdebugread.c:654:11: error: invalid conversion from ‘int’ to ‘address_class’ [-fpermissive]
theclass = mdebug_register_index;
^
The "theclass" local is of type enum address_class, however, what it
really holds is an address class index. Class index values by design
match the address class values up until LOC_FINAL_VALUE, but extend
beyond that, so it's not really right to store an address class index
in an enum address_class.
The fix is really the same making the 'theclass' local be of type int,
but while we're at it, we get rid of the goto, and thus the local
becomes the 'aclass_index' parameter in the new add_data_symbol
function.
gdb/ChangeLog:
2015-10-29 Pedro Alves <palves@redhat.com>
* mdebugread.c (add_data_symbol): New function, factored out from
...
(parse_symbol): ... here. Delete 'theclass' local.