aboutsummaryrefslogtreecommitdiff
path: root/gdb/valops.c
diff options
context:
space:
mode:
authorDoug Evans <dje@google.com>2013-08-01 23:59:48 +0000
committerDoug Evans <dje@google.com>2013-08-01 23:59:48 +0000
commitb846d303c6bc86e2e3155a20fa42180f93c46317 (patch)
tree5d6ad0ca0969edfced729a09bcd0878e577b11e1 /gdb/valops.c
parentb52109bc0c37024e7ea36aa4f7c47f1c52cffed7 (diff)
downloadgdb-b846d303c6bc86e2e3155a20fa42180f93c46317.zip
gdb-b846d303c6bc86e2e3155a20fa42180f93c46317.tar.gz
gdb-b846d303c6bc86e2e3155a20fa42180f93c46317.tar.bz2
PR symtab/15695
* valops.c (value_struct_elt): Add missing call to check_typedef. (value_find_oload_method_list): Ditto. testsuite/ * gdb.base/func-ptr.exp: New file. * gdb.base/func-ptr.c: New file.
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 a3ab24f..f527550 100644
--- a/gdb/valops.c
+++ b/gdb/valops.c
@@ -2188,7 +2188,7 @@ value_struct_elt (struct value **argp, struct value **args,
{
*argp = value_ind (*argp);
/* Don't coerce fn pointer to fn and then back again! */
- if (TYPE_CODE (value_type (*argp)) != TYPE_CODE_FUNC)
+ if (TYPE_CODE (check_typedef (value_type (*argp))) != TYPE_CODE_FUNC)
*argp = coerce_array (*argp);
t = check_typedef (value_type (*argp));
}
@@ -2352,7 +2352,7 @@ value_find_oload_method_list (struct value **argp, const char *method,
{
*argp = value_ind (*argp);
/* Don't coerce fn pointer to fn and then back again! */
- if (TYPE_CODE (value_type (*argp)) != TYPE_CODE_FUNC)
+ if (TYPE_CODE (check_typedef (value_type (*argp))) != TYPE_CODE_FUNC)
*argp = coerce_array (*argp);
t = check_typedef (value_type (*argp));
}