GDB (xrefs)
|
#include "defs.h"
#include "charset.h"
#include "symtab.h"
#include "language.h"
#include "objfiles.h"
#include "value.h"
#include "valprint.h"
#include "guile-internal.h"
Go to the source code of this file.
Classes | |
struct | pretty_printer_smob |
struct | pretty_printer_worker_smob |
Enumerations | |
enum | guile_string_repr_result { STRING_REPR_NONE , STRING_REPR_ERROR , STRING_REPR_OK } |
enum | display_hint { HINT_NONE , HINT_ERROR , HINT_ARRAY , HINT_MAP , HINT_STRING } |
Functions | |
static int | ppscm_print_pretty_printer_smob (SCM self, SCM port, scm_print_state *pstate) |
static SCM | gdbscm_make_pretty_printer (SCM name, SCM lookup) |
static int | ppscm_is_pretty_printer (SCM scm) |
static SCM | gdbscm_pretty_printer_p (SCM scm) |
static SCM | ppscm_get_pretty_printer_arg_unsafe (SCM self, int arg_pos, const char *func_name) |
static pretty_printer_smob * | ppscm_get_pretty_printer_smob_arg_unsafe (SCM self, int arg_pos, const char *func_name) |
static SCM | gdbscm_pretty_printer_enabled_p (SCM self) |
static SCM | gdbscm_set_pretty_printer_enabled_x (SCM self, SCM enabled) |
static SCM | gdbscm_pretty_printers (void) |
static SCM | gdbscm_set_pretty_printers_x (SCM printers) |
static int | ppscm_print_pretty_printer_worker_smob (SCM self, SCM port, scm_print_state *pstate) |
static SCM | gdbscm_make_pretty_printer_worker (SCM display_hint, SCM to_string, SCM children) |
static int | ppscm_is_pretty_printer_worker (SCM scm) |
static SCM | gdbscm_pretty_printer_worker_p (SCM scm) |
static SCM | ppscm_make_pp_type_error_exception (const char *message, SCM object) |
static void | ppscm_print_pp_type_error (const char *message, SCM object) |
static SCM | ppscm_search_pp_list (SCM list, SCM value) |
static SCM | ppscm_find_pretty_printer_from_objfiles (SCM value) |
static SCM | ppscm_find_pretty_printer_from_progspace (SCM value) |
static SCM | ppscm_find_pretty_printer_from_gdb (SCM value) |
static SCM | ppscm_find_pretty_printer (SCM value) |
static SCM | ppscm_pretty_print_one_value (SCM printer, struct value **out_value, struct gdbarch *gdbarch, const struct language_defn *language) |
static SCM | ppscm_get_display_hint_scm (SCM printer) |
static enum display_hint | ppscm_get_display_hint_enum (SCM printer) |
static void | ppscm_print_exception_unless_memory_error (SCM exception, struct ui_file *stream) |
static enum guile_string_repr_result | ppscm_print_string_repr (SCM printer, enum display_hint hint, struct ui_file *stream, int recurse, const struct value_print_options *options, struct gdbarch *gdbarch, const struct language_defn *language) |
static void | ppscm_print_children (SCM printer, enum display_hint hint, struct ui_file *stream, int recurse, const struct value_print_options *options, struct gdbarch *gdbarch, const struct language_defn *language, int printed_nothing) |
enum ext_lang_rc | gdbscm_apply_val_pretty_printer (const struct extension_language_defn *extlang, struct value *value, struct ui_file *stream, int recurse, const struct value_print_options *options, const struct language_defn *language) |
void | gdbscm_initialize_pretty_printers (void) |
Variables | |
static const char | pretty_printer_smob_name [] |
static const char | pretty_printer_worker_smob_name [] |
static scm_t_bits | pretty_printer_smob_tag |
static scm_t_bits | pretty_printer_worker_smob_tag |
static SCM | pretty_printer_list |
static SCM | pp_type_error_symbol |
static SCM | ppscm_map_string |
static SCM | ppscm_array_string |
static SCM | ppscm_string_string |
static const scheme_function | pretty_printer_functions [] |
enum display_hint |
Enumerator | |
---|---|
HINT_NONE | |
HINT_ERROR | |
HINT_ARRAY | |
HINT_MAP | |
HINT_STRING |
Definition at line 46 of file scm-pretty-print.c.
Enumerator | |
---|---|
STRING_REPR_NONE | |
STRING_REPR_ERROR | |
STRING_REPR_OK |
Definition at line 34 of file scm-pretty-print.c.
enum ext_lang_rc gdbscm_apply_val_pretty_printer | ( | const struct extension_language_defn * | extlang, |
struct value * | value, | ||
struct ui_file * | stream, | ||
int | recurse, | ||
const struct value_print_options * | options, | ||
const struct language_defn * | language | ||
) |
Definition at line 953 of file scm-pretty-print.c.
References type::arch(), EXT_LANG_RC_ERROR, EXT_LANG_RC_NOP, EXT_LANG_RC_OK, gdb_scheme_initialized, gdbscm_is_exception(), gdbscm_is_false, HINT_ERROR, HINT_NONE, type::length(), ppscm_find_pretty_printer(), ppscm_get_display_hint_enum(), ppscm_get_display_hint_scm(), ppscm_is_pretty_printer_worker(), ppscm_print_children(), ppscm_print_exception_unless_memory_error(), ppscm_print_pp_type_error(), ppscm_print_string_repr(), STRING_REPR_ERROR, STRING_REPR_NONE, value_bytes_available(), value_fetch_lazy(), value_lazy(), value_type(), and vlscm_scm_from_value_no_release().
void gdbscm_initialize_pretty_printers | ( | void | ) |
Definition at line 1091 of file scm-pretty-print.c.
References gdbscm_define_functions(), gdbscm_make_smob_type(), pp_type_error_symbol, ppscm_array_string, ppscm_map_string, ppscm_print_pretty_printer_smob(), ppscm_print_pretty_printer_worker_smob(), ppscm_string_string, pretty_printer_functions, pretty_printer_list, pretty_printer_smob_name, pretty_printer_smob_tag, pretty_printer_worker_smob_name, and pretty_printer_worker_smob_tag.
|
static |
Definition at line 148 of file scm-pretty-print.c.
References pretty_printer_smob::base, pretty_printer_smob::enabled, FUNC_NAME, gdbscm_init_gsmob(), gdbscm_is_procedure(), pretty_printer_smob::lookup, name, pretty_printer_smob::name, pretty_printer_smob_name, pretty_printer_smob_tag, and scm_new_smob().
|
static |
Definition at line 292 of file scm-pretty-print.c.
References pretty_printer_worker_smob::base, pretty_printer_worker_smob::children, pretty_printer_worker_smob::display_hint, gdbscm_init_gsmob(), pretty_printer_worker_smob_name, pretty_printer_worker_smob_tag, scm_new_smob(), and pretty_printer_worker_smob::to_string.
|
static |
Definition at line 217 of file scm-pretty-print.c.
References pretty_printer_smob::enabled, FUNC_NAME, and ppscm_get_pretty_printer_smob_arg_unsafe().
|
static |
Definition at line 180 of file scm-pretty-print.c.
References ppscm_is_pretty_printer().
|
static |
Definition at line 319 of file scm-pretty-print.c.
References ppscm_is_pretty_printer_worker().
|
static |
Definition at line 243 of file scm-pretty-print.c.
References pretty_printer_list.
|
static |
Definition at line 229 of file scm-pretty-print.c.
References pretty_printer_smob::enabled, FUNC_NAME, gdbscm_is_true, and ppscm_get_pretty_printer_smob_arg_unsafe().
|
static |
Definition at line 252 of file scm-pretty-print.c.
References FUNC_NAME, gdbscm_is_true, and pretty_printer_list.
|
static |
Definition at line 485 of file scm-pretty-print.c.
References gdbscm_is_true, ppscm_find_pretty_printer_from_gdb(), ppscm_find_pretty_printer_from_objfiles(), and ppscm_find_pretty_printer_from_progspace().
Referenced by gdbscm_apply_val_pretty_printer().
|
static |
Definition at line 469 of file scm-pretty-print.c.
References ppscm_search_pp_list(), and pretty_printer_list.
Referenced by ppscm_find_pretty_printer().
|
static |
Definition at line 428 of file scm-pretty-print.c.
References current_program_space, gdbscm_is_true, program_space::objfiles(), ofscm_objfile_smob_from_objfile(), ofscm_objfile_smob_pretty_printers(), and ppscm_search_pp_list().
Referenced by ppscm_find_pretty_printer().
|
static |
Definition at line 453 of file scm-pretty-print.c.
References current_program_space, ppscm_search_pp_list(), psscm_pspace_smob_from_pspace(), and psscm_pspace_smob_pretty_printers().
Referenced by ppscm_find_pretty_printer().
|
static |
Definition at line 587 of file scm-pretty-print.c.
References gdbscm_is_false, gdbscm_is_true, HINT_ERROR, HINT_NONE, HINT_STRING, ppscm_array_string, ppscm_get_display_hint_scm(), ppscm_map_string, and ppscm_string_string.
Referenced by gdbscm_apply_val_pretty_printer().
|
static |
Definition at line 573 of file scm-pretty-print.c.
References pretty_printer_worker_smob::display_hint.
Referenced by gdbscm_apply_val_pretty_printer(), and ppscm_get_display_hint_enum().
|
static |
Definition at line 189 of file scm-pretty-print.c.
References ppscm_is_pretty_printer(), and pretty_printer_smob_name.
Referenced by ppscm_get_pretty_printer_smob_arg_unsafe().
|
static |
Definition at line 202 of file scm-pretty-print.c.
References ppscm_get_pretty_printer_arg_unsafe().
Referenced by gdbscm_pretty_printer_enabled_p(), and gdbscm_set_pretty_printer_enabled_x().
|
static |
Definition at line 172 of file scm-pretty-print.c.
References pretty_printer_smob_tag.
Referenced by gdbscm_pretty_printer_p(), ppscm_get_pretty_printer_arg_unsafe(), and ppscm_search_pp_list().
|
static |
Definition at line 311 of file scm-pretty-print.c.
References pretty_printer_worker_smob_tag.
Referenced by gdbscm_apply_val_pretty_printer(), gdbscm_pretty_printer_worker_p(), and ppscm_search_pp_list().
|
static |
Definition at line 328 of file scm-pretty-print.c.
References gdbscm_make_error(), and pp_type_error_symbol.
Referenced by ppscm_pretty_print_one_value(), ppscm_print_pp_type_error(), and ppscm_search_pp_list().
|
static |
Definition at line 520 of file scm-pretty-print.c.
References FUNC_NAME, GDBSCM_ARG_NONE, gdbscm_is_exception(), gdbscm_is_false, gdbscm_memory_error_p, gdbscm_safe_call_1(), lsscm_is_lazy_string(), ppscm_make_pp_type_error_exception(), pretty_printer_worker_smob::to_string, vlscm_convert_value_from_scheme(), and vlscm_is_value().
Referenced by ppscm_print_string_repr().
|
static |
Definition at line 722 of file scm-pretty-print.c.
References value_print_options::addressprint, pretty_printer_worker_smob::children, common_val_print(), FUNC_NAME, gdb_printf(), gdb_puts(), GDBSCM_ARG_NONE, gdbscm_is_exception(), gdbscm_is_false, gdbscm_is_procedure(), gdbscm_memory_error_p, gdbscm_safe_call_1(), gdbscm_scm_to_c_string(), HINT_ARRAY, HINT_MAP, INT_MAX, itscm_is_end_of_iteration(), itscm_is_iterator(), itscm_safe_call_next_x(), lsscm_is_lazy_string(), lsscm_val_print_lazy_string(), value_print_options::max_depth, name, ppscm_print_exception_unless_memory_error(), ppscm_print_pp_type_error(), value_print_options::prettyformat, value_print_options::prettyformat_arrays, value_print_options::prettyformat_structs, value_print_options::print_array_indexes, value_print_options::print_max, print_spaces(), value_print_options::summary, Val_prettyformat, val_print_check_max_depth(), vlscm_convert_value_from_scheme(), and ui_file::wrap_here().
Referenced by gdbscm_apply_val_pretty_printer().
|
static |
Definition at line 610 of file scm-pretty-print.c.
References gdb_printf(), gdbscm_exception_key(), gdbscm_exception_message_to_string(), gdbscm_memory_error_p, and gdbscm_print_gdb_exception().
Referenced by gdbscm_apply_val_pretty_printer(), ppscm_print_children(), and ppscm_print_string_repr().
|
static |
Definition at line 342 of file scm-pretty-print.c.
References gdbscm_print_gdb_exception(), and ppscm_make_pp_type_error_exception().
Referenced by gdbscm_apply_val_pretty_printer(), and ppscm_print_children().
|
static |
Definition at line 129 of file scm-pretty-print.c.
References pretty_printer_smob::enabled, gdbscm_is_true, gdbscm_printf(), pretty_printer_smob::name, and pretty_printer_smob_name.
Referenced by gdbscm_initialize_pretty_printers().
|
static |
Definition at line 268 of file scm-pretty-print.c.
References pretty_printer_worker_smob::children, pretty_printer_worker_smob::display_hint, gdbscm_printf(), pretty_printer_worker_smob_name, and pretty_printer_worker_smob::to_string.
Referenced by gdbscm_initialize_pretty_printers().
|
static |
strict
Definition at line 642 of file scm-pretty-print.c.
References value_print_options::addressprint, builtin_type::builtin_char, common_val_print(), gdb_putc(), gdb_puts(), gdbscm_is_exception(), gdbscm_is_false, gdbscm_scm_to_string(), get(), HINT_STRING, type::length(), lsscm_is_lazy_string(), lsscm_val_print_lazy_string(), ppscm_pretty_print_one_value(), ppscm_print_exception_unless_memory_error(), STRING_REPR_ERROR, STRING_REPR_NONE, STRING_REPR_OK, and target_charset().
Referenced by gdbscm_apply_val_pretty_printer().
|
static |
Definition at line 361 of file scm-pretty-print.c.
References pretty_printer_smob::enabled, gdbscm_is_exception(), gdbscm_is_false, gdbscm_is_procedure(), gdbscm_memory_error_p, gdbscm_safe_call_2(), pretty_printer_smob::lookup, ppscm_is_pretty_printer(), ppscm_is_pretty_printer_worker(), and ppscm_make_pp_type_error_exception().
Referenced by ppscm_find_pretty_printer_from_gdb(), ppscm_find_pretty_printer_from_objfiles(), and ppscm_find_pretty_printer_from_progspace().
|
static |
Definition at line 117 of file scm-pretty-print.c.
Referenced by gdbscm_initialize_pretty_printers(), and ppscm_make_pp_type_error_exception().
|
static |
Definition at line 121 of file scm-pretty-print.c.
Referenced by gdbscm_initialize_pretty_printers(), and ppscm_get_display_hint_enum().
|
static |
Definition at line 120 of file scm-pretty-print.c.
Referenced by gdbscm_initialize_pretty_printers(), and ppscm_get_display_hint_enum().
|
static |
Definition at line 122 of file scm-pretty-print.c.
Referenced by gdbscm_initialize_pretty_printers(), and ppscm_get_display_hint_enum().
|
static |
Definition at line 1034 of file scm-pretty-print.c.
Referenced by gdbscm_initialize_pretty_printers().
|
static |
Definition at line 114 of file scm-pretty-print.c.
Referenced by gdbscm_initialize_pretty_printers(), gdbscm_pretty_printers(), gdbscm_set_pretty_printers_x(), and ppscm_find_pretty_printer_from_gdb().
|
static |
Definition at line 104 of file scm-pretty-print.c.
Referenced by gdbscm_initialize_pretty_printers(), gdbscm_make_pretty_printer(), ppscm_get_pretty_printer_arg_unsafe(), and ppscm_print_pretty_printer_smob().
|
static |
Definition at line 110 of file scm-pretty-print.c.
Referenced by gdbscm_initialize_pretty_printers(), gdbscm_make_pretty_printer(), and ppscm_is_pretty_printer().
|
static |
Definition at line 106 of file scm-pretty-print.c.
Referenced by gdbscm_initialize_pretty_printers(), gdbscm_make_pretty_printer_worker(), and ppscm_print_pretty_printer_worker_smob().
|
static |
Definition at line 111 of file scm-pretty-print.c.
Referenced by gdbscm_initialize_pretty_printers(), gdbscm_make_pretty_printer_worker(), and ppscm_is_pretty_printer_worker().