summaryrefslogtreecommitdiff
path: root/gdb/valops.c
diff options
context:
space:
mode:
authorTom Tromey <tromey@redhat.com>2012-12-14 17:16:15 +0000
committerTom Tromey <tromey@redhat.com>2012-12-14 17:16:15 +0000
commite8d965638a8374af0dff9819622f76f30472bc0b (patch)
treec87cc08e59f92fba9bcf7aabc164c411dd1f5de1 /gdb/valops.c
parent1f82969cb44bf57e2f05f725403cc37f6d2fa5c5 (diff)
downloadgdb-e8d965638a8374af0dff9819622f76f30472bc0b.tar.gz
* symtab.c (check_field): Now static. Move from...
* valops.c (check_field): ... here. Remove. * value.h (check_field): Don't declare.
Diffstat (limited to 'gdb/valops.c')
-rw-r--r--gdb/valops.c36
1 files changed, 0 insertions, 36 deletions
diff --git a/gdb/valops.c b/gdb/valops.c
index 372f1186eeb..fada3a5102a 100644
--- a/gdb/valops.c
+++ b/gdb/valops.c
@@ -3180,42 +3180,6 @@ destructor_name_p (const char *name, struct type *type)
return 0;
}
-/* Given TYPE, a structure/union,
- return 1 if the component named NAME from the ultimate target
- structure/union is defined, otherwise, return 0. */
-
-int
-check_field (struct type *type, const char *name)
-{
- int i;
-
- /* The type may be a stub. */
- CHECK_TYPEDEF (type);
-
- for (i = TYPE_NFIELDS (type) - 1; i >= TYPE_N_BASECLASSES (type); i--)
- {
- const char *t_field_name = TYPE_FIELD_NAME (type, i);
-
- if (t_field_name && (strcmp_iw (t_field_name, name) == 0))
- return 1;
- }
-
- /* C++: If it was not found as a data field, then try to return it
- as a pointer to a method. */
-
- for (i = TYPE_NFN_FIELDS (type) - 1; i >= 0; --i)
- {
- if (strcmp_iw (TYPE_FN_FIELDLIST_NAME (type, i), name) == 0)
- return 1;
- }
-
- for (i = TYPE_N_BASECLASSES (type) - 1; i >= 0; i--)
- if (check_field (TYPE_BASECLASS (type, i), name))
- return 1;
-
- return 0;
-}
-
/* C++: Given an aggregate type CURTYPE, and a member name NAME,
return the appropriate member (or the address of the member, if
WANT_ADDRESS). This function is used to resolve user expressions