Remove deprecated_lval_hack

This removes deprecated_lval_hack and the VALUE_LVAL macro, replacing
all uses with a call to value::lval.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
This commit is contained in:
Tom Tromey
2023-02-09 06:55:48 -07:00
parent 6f9c9d71c2
commit 736355f2e1
28 changed files with 112 additions and 122 deletions

View File

@ -1363,7 +1363,7 @@ fortran_undetermined::value_subarray (value *array,
if (index < lb
|| (dim_type->index_type ()->bounds ()->high.kind () != PROP_UNDEFINED
&& index > ub)
|| (VALUE_LVAL (array) != lval_memory
|| (array->lval () != lval_memory
&& dim_type->index_type ()->bounds ()->high.kind () == PROP_UNDEFINED))
{
if (type_not_associated (dim_type))
@ -1460,7 +1460,7 @@ fortran_undetermined::value_subarray (value *array,
}
else
{
if (VALUE_LVAL (array) == lval_memory)
if (array->lval () == lval_memory)
{
/* If the value we're taking a slice from is not yet loaded, or
the requested slice is outside the values content range then
@ -1637,7 +1637,7 @@ fortran_structop_operation::evaluate (struct type *expect_type,
= gdb::make_array_view (valaddr, elt_type->length ());
elt_type = resolve_dynamic_type (elt_type, view, address);
}
elt = value::zero (elt_type, VALUE_LVAL (elt));
elt = value::zero (elt_type, elt->lval ());
}
return elt;
@ -1872,7 +1872,7 @@ fortran_argument_convert (struct value *value, bool is_artificial)
{
/* If the value is not in the inferior e.g. registers values,
convenience variables and user input. */
if (VALUE_LVAL (value) != lval_memory)
if (value->lval () != lval_memory)
{
struct type *type = value->type ();
const int length = type->length ();