Don't write to inferior_ptid in corelow.c
[deliverable/binutils-gdb.git] / gdb / compile / compile-c-types.c
index c4f5811678eb5dddf0b4b49a6907cf05d830f976..aad35887666865dc9980de34700fd3d4984dba1d 100644 (file)
@@ -40,7 +40,7 @@ static gcc_type
 convert_array (compile_c_instance *context, struct type *type)
 {
   gcc_type element_type;
-  struct type *range = TYPE_INDEX_TYPE (type);
+  struct type *range = type->index_type ();
 
   element_type = context->convert_type (TYPE_TARGET_TYPE (type));
 
@@ -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);
This page took 0.025427 seconds and 4 git commands to generate.