aboutsummaryrefslogtreecommitdiff
path: root/gdb/valops.c
diff options
context:
space:
mode:
authorSimon Marchi <simon.marchi@efficios.com>2020-06-08 15:25:53 -0400
committerSimon Marchi <simon.marchi@efficios.com>2020-06-08 15:26:01 -0400
commit3d967001ecd3b325fc39d7f53ebf7054d1ecd503 (patch)
tree49d06d14ea849b5a58b207dc5e7e4303b3ae0b67 /gdb/valops.c
parent262abc0d67af006a709d0935940f9c9f5f7c5ee5 (diff)
downloadbinutils-3d967001ecd3b325fc39d7f53ebf7054d1ecd503.zip
binutils-3d967001ecd3b325fc39d7f53ebf7054d1ecd503.tar.gz
binutils-3d967001ecd3b325fc39d7f53ebf7054d1ecd503.tar.bz2
gdb: remove TYPE_INDEX_TYPE macro
Remove `TYPE_INDEX_TYPE` macro, changing all the call sites to use `type::index_type` directly. gdb/ChangeLog: * gdbtypes.h (TYPE_INDEX_TYPE): Remove. Change all call sites to use type::index_type instead. Change-Id: I56715df0bdec89463cda6bd341dac0e01b2faf84
Diffstat (limited to 'gdb/valops.c')
-rw-r--r--gdb/valops.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gdb/valops.c b/gdb/valops.c
index bde4684..2bc58ca 100644
--- a/gdb/valops.c
+++ b/gdb/valops.c
@@ -390,7 +390,7 @@ value_cast (struct type *type, struct value *arg2)
if (element_length > 0 && TYPE_ARRAY_UPPER_BOUND_IS_UNDEFINED (type))
{
- struct type *range_type = TYPE_INDEX_TYPE (type);
+ struct type *range_type = type->index_type ();
int val_length = TYPE_LENGTH (type2);
LONGEST low_bound, high_bound, new_length;
@@ -3769,7 +3769,7 @@ value_slice (struct value *array, int lowbound, int length)
if (type_not_associated (array_type))
error (_("array not associated"));
- range_type = TYPE_INDEX_TYPE (array_type);
+ range_type = array_type->index_type ();
if (get_discrete_bounds (range_type, &lowerbound, &upperbound) < 0)
error (_("slice from bad array or bitstring"));