From: Joel Brobecker Date: Tue, 24 Mar 2009 02:00:51 +0000 (+0000) Subject: * ada-lang.c (ada_evaluate_subexp) [OP_ATR_MODULUS]: Use check_typdef X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=31dedfee60c1832aa6c7d7376fce432e94798471;p=binutils-gdb.git * ada-lang.c (ada_evaluate_subexp) [OP_ATR_MODULUS]: Use check_typdef to make sure we try to get the modulus of the actual type, not the associated typedef. --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 73205452798..f6f8c29ce33 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,9 @@ +2009-03-23 Joel Brobecker + + * ada-lang.c (ada_evaluate_subexp) [OP_ATR_MODULUS]: Use check_typdef + to make sure we try to get the modulus of the actual type, not the + associated typedef. + 2009-03-23 Joel Brobecker * ada-lang.c (ada_evaluate_subexp): [OP_ATR_FIRST, OP_ATR_LAST] diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c index b9a0a3d3b11..38902af35e6 100644 --- a/gdb/ada-lang.c +++ b/gdb/ada-lang.c @@ -9010,7 +9010,7 @@ ada_evaluate_subexp (struct type *expect_type, struct expression *exp, case OP_ATR_MODULUS: { - struct type *type_arg = exp->elts[pc + 2].type; + struct type *type_arg = check_typedef (exp->elts[pc + 2].type); evaluate_subexp (NULL_TYPE, exp, pos, EVAL_SKIP); if (noside == EVAL_SKIP)