diff options
Diffstat (limited to 'gcc/cp/pt.c')
-rw-r--r-- | gcc/cp/pt.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/gcc/cp/pt.c b/gcc/cp/pt.c index edfb8a5..93d790b 100644 --- a/gcc/cp/pt.c +++ b/gcc/cp/pt.c @@ -11713,6 +11713,9 @@ value_dependent_expression_p (tree expression) } if (TREE_CODE (expression) == SCOPE_REF) return dependent_scope_ref_p (expression, value_dependent_expression_p); + if (TREE_CODE (expression) == COMPONENT_REF) + return (value_dependent_expression_p (TREE_OPERAND (expression, 0)) + || value_dependent_expression_p (TREE_OPERAND (expression, 1))); /* A constant expression is value-dependent if any subexpression is value-dependent. */ if (IS_EXPR_CODE_CLASS (TREE_CODE_CLASS (TREE_CODE (expression)))) |