GDB (xrefs)

Functions | Variables
/tmp/gdb-8.1/gdb/m2-valprint.c File Reference
`#include "defs.h"`
`#include "symtab.h"`
`#include "gdbtypes.h"`
`#include "expression.h"`
`#include "value.h"`
`#include "valprint.h"`
`#include "language.h"`
`#include "typeprint.h"`
`#include "c-lang.h"`
`#include "m2-lang.h"`
`#include "target.h"`

Go to the source code of this file.

## Functions
static int | print_unpacked_pointer (struct type *type, CORE_ADDR address, CORE_ADDR addr, const struct value_print_options *options, struct ui_file *stream)
static void | m2_print_array_contents (struct type *type, const gdb_byte *valaddr, int embedded_offset, CORE_ADDR address, struct ui_file *stream, int recurse, struct value *val, const struct value_print_options *options, int len)
int | get_long_set_bounds (struct type *type, LONGEST *low, LONGEST *high)
static void | m2_print_long_set (struct type *type, const gdb_byte *valaddr, int embedded_offset, CORE_ADDR address, struct ui_file *stream)
static void | m2_print_unbounded_array (struct type *type, const gdb_byte *valaddr, int embedded_offset, CORE_ADDR address, struct ui_file *stream, int recurse, const struct value_print_options *options)
static void | print_variable_at_address (struct type *type, const gdb_byte *valaddr, struct ui_file *stream, int recurse, const struct value_print_options *options)
void | m2_val_print (struct type *type, int embedded_offset, CORE_ADDR address, struct ui_file *stream, int recurse, struct value *original_value, const struct value_print_options *options)

## Variables
static const struct generic_val_print_decorations | m2_decorations

## Function Documentation

## ◆ get_long_set_bounds()

int get_long_set_bounds | ( | struct type * | type,
|  | LONGEST * | low,
|  | LONGEST * | high
| ) |  |

Definition at line 49 of file m2-valprint.c.

References _, error(), TYPE_CODE, TYPE_CODE_STRUCT, TYPE_FIELD_TYPE, TYPE_HIGH_BOUND, TYPE_INDEX_TYPE, TYPE_LOW_BOUND, TYPE_N_BASECLASSES, and TYPE_NFIELDS.

Referenced by m2_long_set(), and m2_print_long_set().

## ◆ m2_print_array_contents()

static void m2_print_array_contents | ( | struct type * | type,
|  | const gdb_byte * | valaddr,
|  | int | embedded_offset,
|  | CORE_ADDR | address,
|  | struct ui_file * | stream,
|  | int | recurse,
|  | struct value * | val,
|  | const struct value_print_options * | options,
|  | int | len
| ) |  |
| static

Definition at line 262 of file m2-valprint.c.

References value::address, check_typedef(), current_language, value::embedded_offset, value_print_options::format, fprintf_filtered(), language_defn::la_language, language_m2, value_print_options::prettyformat_arrays, print_spaces_filtered(), TYPE_CODE, TYPE_CODE_CHAR, TYPE_CODE_INT, TYPE_LENGTH, val_print_array_elements(), and val_print_string().

Referenced by m2_print_unbounded_array().

## ◆ m2_print_long_set()

static void m2_print_long_set | ( | struct type * | type,
|  | const gdb_byte * | valaddr,
|  | int | embedded_offset,
|  | CORE_ADDR | address,
|  | struct ui_file * | stream
| ) |  |
| static

Definition at line 69 of file m2-valprint.c.

References _, check_typedef(), error(), fprintf_filtered(), get_discrete_bounds(), get_long_set_bounds(), print_type_scalar(), range, TYPE_FIELD_BITPOS, TYPE_FIELD_TYPE, TYPE_INDEX_TYPE, TYPE_N_BASECLASSES, TYPE_NFIELDS, TYPE_TARGET_TYPE, and value_bit_index().

Referenced by m2_val_print().

## ◆ m2_print_unbounded_array()

static void m2_print_unbounded_array | ( | struct type * | type,
|  | const gdb_byte * | valaddr,
|  | int | embedded_offset,
|  | CORE_ADDR | address,
|  | struct ui_file * | stream,
|  | int | recurse,
|  | const struct value_print_options * | options
| ) |  |
| static

Definition at line 160 of file m2-valprint.c.

References check_typedef(), value::embedded_offset, fprintf_filtered(), m2_print_array_contents(), TYPE_FIELD_BITPOS, TYPE_FIELD_TYPE, TYPE_TARGET_TYPE, unpack_field_as_long(), unpack_pointer(), value_at_lazy(), value_contents_for_printing(), value_embedded_offset(), and value_type().

Referenced by m2_val_print().

## ◆ m2_val_print()

void m2_val_print | ( | struct type * | type,
|  | int | embedded_offset,
|  | CORE_ADDR | address,
|  | struct ui_file * | stream,
|  | int | recurse,
|  | struct value * | original_value,
|  | const struct value_print_options * | options
| ) |  |

Definition at line 311 of file m2-valprint.c.

References _, check_typedef(), cp_print_value_fields(), current_language, value_print_options::format, fprintf_filtered(), fputs_filtered(), gdb_flush(), generic_val_print(), get_discrete_bounds(), language_defn::la_language, LA_PRINT_STRING, language_m2, m2_decorations, m2_is_long_set(), m2_is_unbounded_array(), m2_print_long_set(), m2_print_unbounded_array(), value_print_options::prettyformat_arrays, print_spaces_filtered(), print_type_scalar(), print_unpacked_pointer(), print_variable_at_address(), value_print_options::stop_print_at_null, TYPE_CODE, TYPE_CODE_ARRAY, TYPE_CODE_BOOL, TYPE_CODE_CHAR, TYPE_CODE_ENUM, TYPE_CODE_ERROR, TYPE_CODE_FLT, TYPE_CODE_FUNC, TYPE_CODE_INT, TYPE_CODE_METHOD, TYPE_CODE_PTR, TYPE_CODE_RANGE, TYPE_CODE_REF, TYPE_CODE_SET, TYPE_CODE_STRUCT, TYPE_CODE_UNDEF, TYPE_CODE_UNION, TYPE_CODE_VOID, TYPE_CONST, TYPE_INDEX_TYPE, TYPE_LENGTH, TYPE_STUB, TYPE_TARGET_TYPE, value_print_options::unionprint, unpack_pointer(), val_print_array_elements(), val_print_scalar_formatted(), value_bit_index(), and value_contents_for_printing().

## ◆ print_unpacked_pointer()

static int print_unpacked_pointer | ( | struct type * | type,
|  | CORE_ADDR | address,
|  | CORE_ADDR | addr,
|  | const struct value_print_options * | options,
|  | struct ui_file * | stream
| ) |  |
| static

Definition at line 188 of file m2-valprint.c.

References value_print_options::addressprint, check_typedef(), value_print_options::format, fputs_filtered(), get_type_arch(), paddress(), print_function_pointer_address(), TYPE_CODE, TYPE_CODE_FUNC, TYPE_CODE_INT, TYPE_LENGTH, TYPE_TARGET_TYPE, and val_print_string().

Referenced by m2_val_print().

## ◆ print_variable_at_address()

static void print_variable_at_address | ( | struct type * | type,
|  | const gdb_byte * | valaddr,
|  | struct ui_file * | stream,
|  | int | recurse,
|  | const struct value_print_options * | options
| ) |  |
| static

Definition at line 229 of file m2-valprint.c.

References check_typedef(), common_val_print(), current_language, fprintf_filtered(), fputs_filtered(), get_type_arch(), paddress(), TYPE_CODE, TYPE_CODE_UNDEF, TYPE_TARGET_TYPE, unpack_pointer(), and value_at().

Referenced by m2_val_print().

## Variable Documentation

## ◆ m2_decorations

const struct generic_val_print_decorations m2_decorations
| static

Initial value:
=
{
"",
" + ",
" * I",
"TRUE",
"FALSE",
"void",
"{",
"}"
}

Definition at line 295 of file m2-valprint.c.

Referenced by m2_val_print().