forked from Imagelibrary/binutils-gdb
gdb/ada-lang.c: Rename local variable typename into type_name...
... to avoid a build failure when building with C++ compiler
(when configured with --enable-build-with-cxx). We cannot use
"typename" as it is a C++ reserved keyword.
gdb/ChangeLog:
* ada-lang.c (to_fixed_array_type): Rename local variable
typename into type_name.
This commit is contained in:
@@ -1,3 +1,8 @@
|
|||||||
|
2015-05-20 Joel Brobecker <brobecker@adacore.com>
|
||||||
|
|
||||||
|
* ada-lang.c (to_fixed_array_type): Rename local variable
|
||||||
|
typename into type_name.
|
||||||
|
|
||||||
2015-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
|
2015-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
|
||||||
|
|
||||||
Fix ASAN crash for gdb.compile/compile.exp.
|
Fix ASAN crash for gdb.compile/compile.exp.
|
||||||
|
|||||||
@@ -8582,16 +8582,16 @@ to_fixed_array_type (struct type *type0, struct value *dval,
|
|||||||
|
|
||||||
if (index_type_desc == NULL)
|
if (index_type_desc == NULL)
|
||||||
{
|
{
|
||||||
const char *typename = ada_type_name (type0);
|
const char *type_name = ada_type_name (type0);
|
||||||
|
|
||||||
if (typename != NULL)
|
if (type_name != NULL)
|
||||||
{
|
{
|
||||||
const int len = strlen (typename);
|
const int len = strlen (type_name);
|
||||||
char *name = (char *) alloca (len + strlen (xa_suffix));
|
char *name = (char *) alloca (len + strlen (xa_suffix));
|
||||||
|
|
||||||
if (typename[len - 1] == 'P')
|
if (type_name[len - 1] == 'P')
|
||||||
{
|
{
|
||||||
strcpy (name, typename);
|
strcpy (name, type_name);
|
||||||
strcpy (name + len - 1, xa_suffix);
|
strcpy (name + len - 1, xa_suffix);
|
||||||
index_type_desc = ada_find_parallel_type_with_name (type0, name);
|
index_type_desc = ada_find_parallel_type_with_name (type0, name);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user