summaryrefslogtreecommitdiff
path: root/gdb/completer.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/completer.c')
-rw-r--r--gdb/completer.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gdb/completer.c b/gdb/completer.c
index d03dc77c65d..ad33b98c696 100644
--- a/gdb/completer.c
+++ b/gdb/completer.c
@@ -1090,7 +1090,7 @@ add_struct_fields (struct type *type, completion_list &output,
const char *type_name = NULL;
type = check_typedef (type);
- for (i = 0; i < TYPE_NFIELDS (type); ++i)
+ for (i = 0; i < type->num_fields (); ++i)
{
if (i < TYPE_N_BASECLASSES (type))
add_struct_fields (TYPE_BASECLASS (type, i),