diff options
author | Tom Tromey <tom@tromey.com> | 2023-01-31 16:13:08 -0700 |
---|---|---|
committer | Tom Tromey <tom@tromey.com> | 2023-02-13 15:22:17 -0700 |
commit | d00664dbba2802bacfed2335b6f249fc418182a0 (patch) | |
tree | d926f7656d767617427844def6d80e8e72817207 /gdb/stack.c | |
parent | cda0334434412d888443e9a98386255f2e0c2eab (diff) | |
download | gdb-d00664dbba2802bacfed2335b6f249fc418182a0.zip gdb-d00664dbba2802bacfed2335b6f249fc418182a0.tar.gz gdb-d00664dbba2802bacfed2335b6f249fc418182a0.tar.bz2 |
Turn many optimized-out value functions into methods
This turns many functions that are related to optimized-out or
availability-checking to be methods of value. The static function
value_entirely_covered_by_range_vector is also converted to be a
private method.
Approved-By: Simon Marchi <simon.marchi@efficios.com>
Diffstat (limited to 'gdb/stack.c')
-rw-r--r-- | gdb/stack.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/gdb/stack.c b/gdb/stack.c index 576947c..934220e 100644 --- a/gdb/stack.c +++ b/gdb/stack.c @@ -550,7 +550,7 @@ read_frame_arg (const frame_print_options &fp_opts, && SYMBOL_COMPUTED_OPS (sym)->read_variable_at_entry != NULL && fp_opts.print_entry_values != print_entry_values_no && (fp_opts.print_entry_values != print_entry_values_if_needed - || !val || value_optimized_out (val))) + || !val || val->optimized_out ())) { try { @@ -568,7 +568,7 @@ read_frame_arg (const frame_print_options &fp_opts, } } - if (entryval != NULL && value_optimized_out (entryval)) + if (entryval != NULL && entryval->optimized_out ()) entryval = NULL; if (fp_opts.print_entry_values == print_entry_values_compact @@ -672,7 +672,7 @@ read_frame_arg (const frame_print_options &fp_opts, if (fp_opts.print_entry_values == print_entry_values_only || fp_opts.print_entry_values == print_entry_values_both || (fp_opts.print_entry_values == print_entry_values_preferred - && (!val || value_optimized_out (val)))) + && (!val || val->optimized_out ()))) { entryval = value::allocate_optimized_out (sym->type ()); entryval_error = NULL; @@ -681,7 +681,7 @@ read_frame_arg (const frame_print_options &fp_opts, if ((fp_opts.print_entry_values == print_entry_values_compact || fp_opts.print_entry_values == print_entry_values_if_needed || fp_opts.print_entry_values == print_entry_values_preferred) - && (!val || value_optimized_out (val)) && entryval != NULL) + && (!val || val->optimized_out ()) && entryval != NULL) { val = NULL; val_error = NULL; @@ -1708,7 +1708,7 @@ info_frame_command_core (frame_info_ptr fi, bool selected_frame_p) struct value *value = frame_unwind_register_value (fi, sp_regnum); gdb_assert (value != NULL); - if (!value_optimized_out (value) && value_entirely_available (value)) + if (!value->optimized_out () && value->entirely_available ()) { if (VALUE_LVAL (value) == not_lval) { |