Simplify ada_lookup_struct_elt_type
authorTom Tromey <tromey@adacore.com>
Mon, 5 Jun 2023 18:30:09 +0000 (12:30 -0600)
committerTom Tromey <tromey@adacore.com>
Wed, 7 Jun 2023 15:31:59 +0000 (09:31 -0600)
commitf0874f419209510d2a55e994f6ca10eb9f7905bc
tree0472deb4929925e8193ebf31e0c5f4991691a967
parent064ad3ea5ecbc30de1eb52a22ac73fea1b5dcc5b
Simplify ada_lookup_struct_elt_type

This patch simplifies ada_lookup_struct_elt_type by changing it to
call find_struct_field.  The two functions were substantially similar,
even to the point of having identical comments.

I tested this using both the gdb test suite and the internal AdaCore
test suite.  Given this and the fact that it is Ada-specific, I am
checking it in.
gdb/ada-lang.c