if (type->num_fields () == 2)
{
- struct type *type0 = TYPE_FIELD_TYPE (type, 0);
- struct type *type1 = TYPE_FIELD_TYPE (type, 1);
+ struct type *type0 = type->field (0).type ();
+ struct type *type1 = type->field (1).type ();
type0 = check_typedef (type0);
type1 = check_typedef (type1);
c_printchar, /* Print a character constant. */
c_printstr, /* Function to print string constant. */
c_emit_char, /* Print a single char. */
- go_print_type, /* Print a type using appropriate syntax. */
c_print_typedef, /* Print a typedef using appropriate
syntax. */
go_value_print_inner, /* la_value_print_inner */
c_value_print, /* Print a top-level value. */
- NULL, /* Language specific skip_trampoline. */
NULL, /* name_of_this */
false, /* la_store_sym_names_in_linkage_form_p */
basic_lookup_symbol_nonlocal,
- go_demangle, /* Language specific symbol demangler. */
- NULL, /* Language specific
- class_name_from_physname. */
go_op_print_tab, /* Expression operators for printing. */
1, /* C-style arrays. */
0, /* String lower bound. */
- default_word_break_characters,
default_collect_symbol_completion_matches,
c_watch_location_expression,
- NULL, /* la_get_symbol_name_matcher */
&default_varobj_ops,
- NULL,
go_is_string_type_p,
"{...}" /* la_struct_too_deep_ellipsis */
};
*demangled = go_demangle (mangled, 0);
return *demangled != NULL;
}
+
+ /* See language.h. */
+
+ char *demangle (const char *mangled, int options) const override
+ {
+ return go_demangle (mangled, options);
+ }
+
+ /* See language.h. */
+
+ void print_type (struct type *type, const char *varstring,
+ struct ui_file *stream, int show, int level,
+ const struct type_print_options *flags) const override
+ {
+ go_print_type (type, varstring, stream, show, level, flags);
+ }
};
/* Single instance of the Go language class. */