Fix dumping of function arguments.
gdb/ChangeLog: * gdbtypes.c (print_args): Renamed from print_arg_types. Print arg number and name if present. All callers updated. (dump_fn_fieldlists): Fix indentation of args.
This commit is contained in:
parent
e05fa0bad2
commit
4c9e848275
|
@ -1,3 +1,9 @@
|
||||||
|
2014-11-23 Doug Evans <xdje42@gmail.com>
|
||||||
|
|
||||||
|
* gdbtypes.c (print_args): Renamed from print_arg_types. Print arg
|
||||||
|
number and name if present. All callers updated.
|
||||||
|
(dump_fn_fieldlists): Fix indentation of args.
|
||||||
|
|
||||||
2014-11-23 Patrick Palka <patrick@parcs.ath.cx>
|
2014-11-23 Patrick Palka <patrick@parcs.ath.cx>
|
||||||
|
|
||||||
* MAINTAINERS (Write After Approval): Add myself.
|
* MAINTAINERS (Write After Approval): Add myself.
|
||||||
|
|
|
@ -3509,14 +3509,18 @@ print_bit_vector (B_TYPE *bits, int nbits)
|
||||||
situation. */
|
situation. */
|
||||||
|
|
||||||
static void
|
static void
|
||||||
print_arg_types (struct field *args, int nargs, int spaces)
|
print_args (struct field *args, int nargs, int spaces)
|
||||||
{
|
{
|
||||||
if (args != NULL)
|
if (args != NULL)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
for (i = 0; i < nargs; i++)
|
for (i = 0; i < nargs; i++)
|
||||||
recursive_dump_type (args[i].type, spaces + 2);
|
{
|
||||||
|
printfi_filtered (spaces, "[%d] name '%s'\n", i,
|
||||||
|
args[i].name != NULL ? args[i].name : "<NULL>");
|
||||||
|
recursive_dump_type (args[i].type, spaces + 2);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -3574,11 +3578,9 @@ dump_fn_fieldlists (struct type *type, int spaces)
|
||||||
gdb_print_host_address (TYPE_FN_FIELD_ARGS (f, overload_idx),
|
gdb_print_host_address (TYPE_FN_FIELD_ARGS (f, overload_idx),
|
||||||
gdb_stdout);
|
gdb_stdout);
|
||||||
printf_filtered ("\n");
|
printf_filtered ("\n");
|
||||||
|
print_args (TYPE_FN_FIELD_ARGS (f, overload_idx),
|
||||||
print_arg_types (TYPE_FN_FIELD_ARGS (f, overload_idx),
|
TYPE_NFIELDS (TYPE_FN_FIELD_TYPE (f, overload_idx)),
|
||||||
TYPE_NFIELDS (TYPE_FN_FIELD_TYPE (f,
|
spaces + 8 + 2);
|
||||||
overload_idx)),
|
|
||||||
spaces);
|
|
||||||
printfi_filtered (spaces + 8, "fcontext ");
|
printfi_filtered (spaces + 8, "fcontext ");
|
||||||
gdb_print_host_address (TYPE_FN_FIELD_FCONTEXT (f, overload_idx),
|
gdb_print_host_address (TYPE_FN_FIELD_FCONTEXT (f, overload_idx),
|
||||||
gdb_stdout);
|
gdb_stdout);
|
||||||
|
|
Loading…
Reference in New Issue