From dad6b350f986a58abe469f4584ac515e7ac17879 Mon Sep 17 00:00:00 2001 From: Tom Tromey Date: Sun, 12 Jun 2022 14:13:22 -0600 Subject: Use bool constants for value_print_options This changes the uses of value_print_options to use 'true' and 'false' rather than integers. --- gdb/guile/scm-pretty-print.c | 6 +++--- gdb/guile/scm-value.c | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) (limited to 'gdb/guile') diff --git a/gdb/guile/scm-pretty-print.c b/gdb/guile/scm-pretty-print.c index 5e6bb12..9e42a4d 100644 --- a/gdb/guile/scm-pretty-print.c +++ b/gdb/guile/scm-pretty-print.c @@ -660,7 +660,7 @@ ppscm_print_string_repr (SCM printer, enum display_hint hint, struct value_print_options opts = *options; gdb_assert (replacement != NULL); - opts.addressprint = 0; + opts.addressprint = false; common_val_print (replacement, stream, recurse, &opts, language); result = STRING_REPR_OK; } @@ -698,7 +698,7 @@ ppscm_print_string_repr (SCM printer, enum display_hint hint, { struct value_print_options local_opts = *options; - local_opts.addressprint = 0; + local_opts.addressprint = false; lsscm_val_print_lazy_string (str_scm, stream, &local_opts); result = STRING_REPR_OK; } @@ -883,7 +883,7 @@ ppscm_print_children (SCM printer, enum display_hint hint, { struct value_print_options local_opts = *options; - local_opts.addressprint = 0; + local_opts.addressprint = false; lsscm_val_print_lazy_string (v_scm, stream, &local_opts); } else if (scm_is_string (v_scm)) diff --git a/gdb/guile/scm-value.c b/gdb/guile/scm-value.c index 0107a4b..8ff2823 100644 --- a/gdb/guile/scm-value.c +++ b/gdb/guile/scm-value.c @@ -148,7 +148,7 @@ vlscm_print_value_smob (SCM self, SCM port, scm_print_state *pstate) gdbscm_printf (port, "#<%s ", value_smob_name); get_user_print_options (&opts); - opts.deref_ref = 0; + opts.deref_ref = false; /* pstate->writingp = zero if invoked by display/~A, and nonzero if invoked by write/~S. What to do here may need to evolve. @@ -1264,7 +1264,7 @@ gdbscm_value_print (SCM self) struct value_print_options opts; get_user_print_options (&opts); - opts.deref_ref = 0; + opts.deref_ref = false; string_file stb; -- cgit v1.1