summaryrefslogtreecommitdiff
path: root/gcc/cp/lex.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/cp/lex.c')
-rw-r--r--gcc/cp/lex.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/cp/lex.c b/gcc/cp/lex.c
index 1f8cb0672a3..b378dc1724a 100644
--- a/gcc/cp/lex.c
+++ b/gcc/cp/lex.c
@@ -777,7 +777,7 @@ do_identifier (register tree token, tree args)
{
/* Check access. */
if (IDENTIFIER_CLASS_VALUE (token) == id)
- perform_or_defer_access_check (CP_DECL_CONTEXT(id), id);
+ perform_or_defer_access_check (TYPE_BINFO (DECL_CONTEXT (id)), id);
if (!processing_template_decl || DECL_TEMPLATE_PARM_P (id))
id = DECL_INITIAL (id);
}