aboutsummaryrefslogtreecommitdiff
path: root/gcc/cp/expr.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/cp/expr.c')
-rw-r--r--gcc/cp/expr.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/gcc/cp/expr.c b/gcc/cp/expr.c
index 77af54e..75e99e5 100644
--- a/gcc/cp/expr.c
+++ b/gcc/cp/expr.c
@@ -133,6 +133,9 @@ mark_exp_read (tree exp)
switch (TREE_CODE (exp))
{
case VAR_DECL:
+ if (DECL_VALUE_EXPR (exp))
+ mark_exp_read (DECL_VALUE_EXPR (exp));
+ gcc_fallthrough ();
case PARM_DECL:
DECL_READ_P (exp) = 1;
break;