aboutsummaryrefslogtreecommitdiff
path: root/gdb/rx-tdep.c
diff options
context:
space:
mode:
authorSimon Marchi <simon.marchi@efficios.com>2020-05-22 16:55:15 -0400
committerSimon Marchi <simon.marchi@efficios.com>2020-05-22 16:55:15 -0400
commit1f704f761b34e145f5eabdc222301ce6e9ec9102 (patch)
tree89c8b6dbf40b606ef045929b718d9271093057a3 /gdb/rx-tdep.c
parent5e33d5f4e1a5f2c3556ee31715ddc030d039b597 (diff)
downloadgdb-1f704f761b34e145f5eabdc222301ce6e9ec9102.zip
gdb-1f704f761b34e145f5eabdc222301ce6e9ec9102.tar.gz
gdb-1f704f761b34e145f5eabdc222301ce6e9ec9102.tar.bz2
gdb: remove TYPE_NFIELDS macro
Remove `TYPE_NFIELDS`, changing all the call sites to use `type::num_fields` directly. This is quite a big diff, but this was mostly done using sed and coccinelle. A few call sites were done by hand. gdb/ChangeLog: * gdbtypes.h (TYPE_NFIELDS): Remove. Change all cal sites to use type::num_fields instead. Change-Id: Ib73be4c36f9e770e0f729bac3b5257d7cb2f9591
Diffstat (limited to 'gdb/rx-tdep.c')
-rw-r--r--gdb/rx-tdep.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gdb/rx-tdep.c b/gdb/rx-tdep.c
index 9963bc3..0a9b1e8 100644
--- a/gdb/rx-tdep.c
+++ b/gdb/rx-tdep.c
@@ -687,7 +687,7 @@ rx_push_dummy_call (struct gdbarch *gdbarch, struct value *function,
of the ``arg_reg'' variable to get these other details correct. */
if (TYPE_VARARGS (func_type))
- num_register_candidate_args = TYPE_NFIELDS (func_type) - 1;
+ num_register_candidate_args = func_type->num_fields () - 1;
else
num_register_candidate_args = 4;
@@ -796,7 +796,7 @@ rx_push_dummy_call (struct gdbarch *gdbarch, struct value *function,
int p_arg_size = 4;
if (TYPE_PROTOTYPED (func_type)
- && i < TYPE_NFIELDS (func_type))
+ && i < func_type->num_fields ())
{
struct type *p_arg_type =
TYPE_FIELD_TYPE (func_type, i);