static struct type *
vtable_ptrdiff_type (struct gdbarch *gdbarch)
{
- struct type *vtable_type = gdbarch_data (gdbarch, vtable_type_gdbarch_data);
+ struct type *vtable_type
+ = (struct type *) gdbarch_data (gdbarch, vtable_type_gdbarch_data);
/* The "offset_to_top" field has the appropriate (ptrdiff_t) type. */
return TYPE_FIELD_TYPE (vtable_type, vtable_field_offset_to_top);
static int
vtable_address_point_offset (struct gdbarch *gdbarch)
{
- struct type *vtable_type = gdbarch_data (gdbarch, vtable_type_gdbarch_data);
+ struct type *vtable_type
+ = (struct type *) gdbarch_data (gdbarch, vtable_type_gdbarch_data);
return (TYPE_FIELD_BITPOS (vtable_type, vtable_field_virtual_functions)
/ TARGET_CHAR_BIT);
gnuv3_get_vtable (struct gdbarch *gdbarch,
struct type *container_type, CORE_ADDR container_addr)
{
- struct type *vtable_type = gdbarch_data (gdbarch,
- vtable_type_gdbarch_data);
+ struct type *vtable_type
+ = (struct type *) gdbarch_data (gdbarch, vtable_type_gdbarch_data);
struct type *vtable_pointer_type;
struct value *vtable_pointer;
CORE_ADDR vtable_address;
{
char *copy;
- copy = alloca (atsign - class_name + 1);
+ copy = (char *) alloca (atsign - class_name + 1);
memcpy (copy, class_name, atsign - class_name);
copy[atsign - class_name] = '\0';
class_name = copy;
static hashval_t
hash_value_and_voffset (const void *p)
{
- const struct value_and_voffset *o = p;
+ const struct value_and_voffset *o = (const struct value_and_voffset *) p;
return value_address (o->value) + value_embedded_offset (o->value);
}
static int
eq_value_and_voffset (const void *a, const void *b)
{
- const struct value_and_voffset *ova = a;
- const struct value_and_voffset *ovb = b;
+ const struct value_and_voffset *ova = (const struct value_and_voffset *) a;
+ const struct value_and_voffset *ovb = (const struct value_and_voffset *) b;
return (value_address (ova->value) + value_embedded_offset (ova->value)
== value_address (ovb->value) + value_embedded_offset (ovb->value));
static int
compare_value_and_voffset (const void *a, const void *b)
{
- const struct value_and_voffset * const *ova = a;
+ const struct value_and_voffset * const *ova
+ = (const struct value_and_voffset * const *) a;
CORE_ADDR addra = (value_address ((*ova)->value)
+ value_embedded_offset ((*ova)->value));
- const struct value_and_voffset * const *ovb = b;
+ const struct value_and_voffset * const *ovb
+ = (const struct value_and_voffset * const *) b;
CORE_ADDR addrb = (value_address ((*ovb)->value)
+ value_embedded_offset ((*ovb)->value));
search_vo.value = value;
slot = htab_find_slot (offset_hash, &search_vo, INSERT);
if (*slot)
- current_vo = *slot;
+ current_vo = (struct value_and_voffset *) *slot;
else
{
current_vo = XNEW (struct value_and_voffset);
typeinfo = lookup_symbol ("std::type_info", NULL, STRUCT_DOMAIN,
NULL).symbol;
if (typeinfo == NULL)
- typeinfo_type = gdbarch_data (gdbarch, std_type_info_gdbarch_data);
+ typeinfo_type
+ = (struct type *) gdbarch_data (gdbarch, std_type_info_gdbarch_data);
else
typeinfo_type = SYMBOL_TYPE (typeinfo);