gdb: remove TYPE_FIELD_DWARF_BLOCK
authorSimon Marchi <simon.marchi@polymtl.ca>
Mon, 27 Sep 2021 01:08:36 +0000 (21:08 -0400)
committerSimon Marchi <simon.marchi@polymtl.ca>
Fri, 29 Oct 2021 20:44:45 +0000 (16:44 -0400)
Remove TYPE_FIELD_DWARF_BLOCK, replace with type::field +
field::loc_dwarf_block.

Change-Id: I10af9410bb5f46d342b8358a7956998c7e804b64

gdb/gdbtypes.c
gdb/gdbtypes.h
gdb/gnu-v3-abi.c

index 752148965097b776cf5088234b1544d9ba57c9f1..00934d9a4bc85c9612a2896d6da7f2b5cfbb858e 100644 (file)
@@ -2591,7 +2591,7 @@ resolve_dynamic_struct (struct type *type,
          struct dwarf2_property_baton baton;
          baton.property_type
            = lookup_pointer_type (resolved_type->field (i).type ());
-         baton.locexpr = *TYPE_FIELD_DWARF_BLOCK (resolved_type, i);
+         baton.locexpr = *resolved_type->field (i).loc_dwarf_block ();
 
          struct dynamic_prop prop;
          prop.set_locexpr (&baton);
@@ -5577,7 +5577,7 @@ copy_type_recursive (struct objfile *objfile,
              break;
             case FIELD_LOC_KIND_DWARF_BLOCK:
               new_type->field (i).set_loc_dwarf_block
-               (TYPE_FIELD_DWARF_BLOCK (type, i));
+               (type->field (i).loc_dwarf_block ());
               break;
            default:
              internal_error (__FILE__, __LINE__,
index 1f5dc657b1c9fa72f8b5bfa5dca2bed65f26aaa1..5284a4c3a030bd7b8d02132fdbfb753bc94bab73 100644 (file)
@@ -2128,7 +2128,6 @@ extern void set_type_vptr_basetype (struct type *, struct type *);
 #define FIELD_ARTIFICIAL(thisfld) ((thisfld).artificial)
 #define FIELD_BITSIZE(thisfld) ((thisfld).bitsize)
 
-#define TYPE_FIELD_DWARF_BLOCK(thistype, n) ((thistype)->field (n).loc_dwarf_block ())
 #define TYPE_FIELD_ARTIFICIAL(thistype, n) FIELD_ARTIFICIAL((thistype)->field (n))
 #define TYPE_FIELD_BITSIZE(thistype, n) FIELD_BITSIZE((thistype)->field (n))
 #define TYPE_FIELD_PACKED(thistype, n) (FIELD_BITSIZE((thistype)->field (n))!=0)
index 80b7eddd87871b867440714ef7b29e3bfd089ce5..187c10595acbf6a82b747089baba774b96e0e7cb 100644 (file)
@@ -469,7 +469,7 @@ gnuv3_baseclass_offset (struct type *type, int index,
       struct dwarf2_property_baton baton;
       baton.property_type
        = lookup_pointer_type (type->field (index).type ());
-      baton.locexpr = *TYPE_FIELD_DWARF_BLOCK (type, index);
+      baton.locexpr = *type->field (index).loc_dwarf_block ();
 
       struct dynamic_prop prop;
       prop.set_locexpr (&baton);