+public:
+ auto_or_unknown_language (enum language lang)
+ : language_defn (lang)
+ { /* Nothing. */ }
+
+ /* See language.h. */
+ void language_arch_info (struct gdbarch *gdbarch,
+ struct language_arch_info *lai) const override
+ {
+ lai->set_string_char_type (builtin_type (gdbarch)->builtin_char);
+ lai->set_bool_type (builtin_type (gdbarch)->builtin_int);
+ }
+
+ /* 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
+ {
+ error (_("type printing not implemented for language \"%s\""),
+ natural_name ());
+ }
+
+ /* See language.h. */
+
+ gdb::unique_xmalloc_ptr<char> demangle_symbol (const char *mangled,
+ int options) const override
+ {
+ /* The auto language just uses the C++ demangler. */
+ return gdb_demangle (mangled, options);
+ }
+
+ /* See language.h. */
+
+ void value_print (struct value *val, struct ui_file *stream,
+ const struct value_print_options *options) const override
+ {
+ error (_("value printing not implemented for language \"%s\""),
+ natural_name ());
+ }
+
+ /* See language.h. */
+
+ void value_print_inner
+ (struct value *val, struct ui_file *stream, int recurse,
+ const struct value_print_options *options) const override
+ {
+ error (_("inner value printing not implemented for language \"%s\""),
+ natural_name ());
+ }
+
+ /* See language.h. */
+
+ int parser (struct parser_state *ps) const override
+ {
+ error (_("expression parsing not implemented for language \"%s\""),
+ natural_name ());
+ }
+
+ /* See language.h. */
+
+ void emitchar (int ch, struct type *chtype,
+ struct ui_file *stream, int quoter) const override
+ {
+ error (_("emit character not implemented for language \"%s\""),
+ natural_name ());
+ }
+
+ /* See language.h. */
+
+ void printchar (int ch, struct type *chtype,
+ struct ui_file *stream) const override
+ {
+ error (_("print character not implemented for language \"%s\""),
+ natural_name ());
+ }
+
+ /* See language.h. */
+
+ void printstr (struct ui_file *stream, struct type *elttype,
+ const gdb_byte *string, unsigned int length,
+ const char *encoding, int force_ellipses,
+ const struct value_print_options *options) const override
+ {
+ error (_("print string not implemented for language \"%s\""),
+ natural_name ());
+ }
+
+ /* See language.h. */
+
+ void print_typedef (struct type *type, struct symbol *new_symbol,
+ struct ui_file *stream) const override
+ {
+ error (_("print typedef not implemented for language \"%s\""),
+ natural_name ());
+ }
+
+ /* See language.h. */
+
+ bool is_string_type_p (struct type *type) const override
+ {
+ type = check_typedef (type);
+ while (type->code () == TYPE_CODE_REF)
+ {
+ type = TYPE_TARGET_TYPE (type);
+ type = check_typedef (type);
+ }
+ return (type->code () == TYPE_CODE_STRING);
+ }