static int print_variant_part (struct type *type, int field_num, const gdb_byte *valaddr, int offset, struct ui_file *stream, int recurse, struct value *val, const struct value_print_options *options, int comma_needed, struct type *outer_type, int outer_offset, const struct language_defn *language) { struct type *var_type = TYPE_FIELD_TYPE (type, field_num); int which = ada_which_variant_applies (var_type, outer_type, valaddr + outer_offset); if (which < 0) return 0; else return print_field_values (TYPE_FIELD_TYPE (var_type, which), valaddr, offset + TYPE_FIELD_BITPOS (type, field_num) / HOST_CHAR_BIT + TYPE_FIELD_BITPOS (var_type, which) / HOST_CHAR_BIT, stream, recurse, val, options, comma_needed, outer_type, outer_offset, language); }
static int print_variant_part (struct type *type, int field_num, char *valaddr, struct ui_file *stream, int format, int recurse, enum val_prettyprint pretty, int comma_needed, struct type *outer_type, char *outer_valaddr) { struct type *var_type = TYPE_FIELD_TYPE (type, field_num); int which = ada_which_variant_applies (var_type, outer_type, outer_valaddr); if (which < 0) return 0; else return print_field_values (TYPE_FIELD_TYPE (var_type, which), valaddr + TYPE_FIELD_BITPOS (type, field_num) / HOST_CHAR_BIT + TYPE_FIELD_BITPOS (var_type, which) / HOST_CHAR_BIT, stream, format, recurse, pretty, comma_needed, outer_type, outer_valaddr); }