49 struct value *temp = arg1;
54 _(
"unbounded structure "
55 "missing _m2_high field"));
80 struct value *temp = arg1;
83 error (_(
"internal error: unbounded "
84 "array structure is unknown"));
87 _(
"unbounded structure "
88 "missing _m2_contents field"));
97 if (
type->
code () != TYPE_CODE_ARRAY)
100 error (_(
"cannot subscript something of type `%s'"),
103 error (_(
"cannot subscript requested type"));
127 auto add = [&] (
struct type * t)
157 const gdb_byte *
string,
unsigned int length,
158 const char *encoding,
int force_ellipses,
162 unsigned int things_printed = 0;
172 for (i = 0; i < length && things_printed < options->
print_max; ++i)
190 while (rep1 < length &&
string[rep1] ==
string[i])
204 gdb_printf (stream,
" <repeats %u times>", reps);
216 emitchar (
string[i], elttype, stream,
'"');
225 if (force_ellipses || i < length)
233 struct ui_file *stream,
int quoter)
const
239 if (ch ==
'\\' || ch == quoter)
269 gdb_printf (stream,
"\\%.3o", (
unsigned int) ch);
305 if (result ==
nullptr)
void emitchar(int ch, struct type *chtype, struct ui_file *stream, int quoter) const override
void language_arch_info(struct gdbarch *gdbarch, struct language_arch_info *lai) const override
void printchar(int ch, struct type *chtype, struct ui_file *stream) const override
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
void set(unsigned key, void *datum)
@ EVAL_AVOID_SIDE_EFFECTS
int gdbarch_int_bit(struct gdbarch *gdbarch)
int gdbarch_float_bit(struct gdbarch *gdbarch)
const struct floatformat ** gdbarch_float_format(struct gdbarch *gdbarch)
struct type * arch_boolean_type(struct gdbarch *gdbarch, int bit, int unsigned_p, const char *name)
struct type * arch_float_type(struct gdbarch *gdbarch, int bit, const char *name, const struct floatformat **floatformats)
struct type * arch_character_type(struct gdbarch *gdbarch, int bit, int unsigned_p, const char *name)
struct type * arch_integer_type(struct gdbarch *gdbarch, int bit, int unsigned_p, const char *name)
struct type * check_typedef(struct type *type)
#define PRINT_LITERAL_FORM(c)
static m2_language m2_language_defn
struct value * eval_op_m2_high(struct type *expect_type, struct expression *exp, enum noside noside, struct value *arg1)
struct value * eval_op_m2_subscript(struct type *expect_type, struct expression *exp, enum noside noside, struct value *arg1, struct value *arg2)
static const registry< gdbarch >::key< struct builtin_m2_type > m2_type_data
static struct builtin_m2_type * build_m2_types(struct gdbarch *gdbarch)
int m2_is_unbounded_array(struct type *type)
struct type * builtin_real
struct type * builtin_char
struct type * builtin_bool
struct type * builtin_card
struct type * builtin_int
struct type * type() const
void set_string_char_type(struct type *type)
void add_primitive_type(struct type *type)
void set_bool_type(struct type *type, const char *name=nullptr)
struct type * target_type() const
struct field & field(int idx) const
const char * name() const
unsigned int repeat_count_threshold
void gdb_printf(struct ui_file *stream, const char *format,...)
void gdb_puts(const char *linebuffer, struct ui_file *stream)
struct value * value_subscript(struct value *array, LONGEST index)
struct value * value_ptradd(struct value *arg1, LONGEST arg2)
struct value * value_struct_elt(struct value **argp, gdb::optional< gdb::array_view< value * > > args, const char *name, int *static_memfuncp, const char *err)
struct value * value_cast(struct type *type, struct value *arg2)
struct value * value_ind(struct value *arg1)
struct type * value_type(const struct value *value)
struct value * value_zero(struct type *type, enum lval_type lv)
struct value * coerce_ref(struct value *arg)
LONGEST value_as_long(struct value *val)