X-Git-Url: http://drtracing.org/?a=blobdiff_plain;f=gdb%2Fcompile%2Fcompile-c-types.c;h=aad35887666865dc9980de34700fd3d4984dba1d;hb=60db1b8565060f4bd2287b060ea9724c93289982;hp=3cf89fddffcc200d978d8e4238bc2dd845cd1831;hpb=3d967001ecd3b325fc39d7f53ebf7054d1ecd503;p=deliverable%2Fbinutils-gdb.git diff --git a/gdb/compile/compile-c-types.c b/gdb/compile/compile-c-types.c index 3cf89fddff..aad3588766 100644 --- a/gdb/compile/compile-c-types.c +++ b/gdb/compile/compile-c-types.c @@ -108,9 +108,9 @@ convert_struct_or_union (compile_c_instance *context, struct type *type) gcc_type field_type; unsigned long bitsize = TYPE_FIELD_BITSIZE (type, i); - field_type = context->convert_type (TYPE_FIELD_TYPE (type, i)); + field_type = context->convert_type (type->field (i).type ()); if (bitsize == 0) - bitsize = 8 * TYPE_LENGTH (TYPE_FIELD_TYPE (type, i)); + bitsize = 8 * TYPE_LENGTH (type->field (i).type ()); context->plugin ().build_add_field (result, TYPE_FIELD_NAME (type, i), field_type, @@ -178,7 +178,7 @@ convert_func (compile_c_instance *context, struct type *type) array.n_elements = type->num_fields (); array.elements = XNEWVEC (gcc_type, type->num_fields ()); for (i = 0; i < type->num_fields (); ++i) - array.elements[i] = context->convert_type (TYPE_FIELD_TYPE (type, i)); + array.elements[i] = context->convert_type (type->field (i).type ()); result = context->plugin ().build_function_type (return_type, &array, is_varargs);