aboutsummaryrefslogtreecommitdiff
path: root/gcc/cp/tree.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/cp/tree.c')
-rw-r--r--gcc/cp/tree.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/gcc/cp/tree.c b/gcc/cp/tree.c
index dbac7f3..aab92d5 100644
--- a/gcc/cp/tree.c
+++ b/gcc/cp/tree.c
@@ -2028,6 +2028,7 @@ build_qualified_name (tree type, tree scope, tree name, bool template_p)
|| scope == error_mark_node
|| name == error_mark_node)
return error_mark_node;
+ gcc_assert (TREE_CODE (name) != SCOPE_REF);
t = build2 (SCOPE_REF, type, scope, name);
QUALIFIED_NAME_IS_TEMPLATE (t) = template_p;
PTRMEM_OK_P (t) = true;
@@ -4663,6 +4664,8 @@ cp_walk_subtrees (tree *tp, int *walk_subtrees_p, walk_tree_fn func,
break;
case BASELINK:
+ if (BASELINK_QUALIFIED_P (*tp))
+ WALK_SUBTREE (BINFO_TYPE (BASELINK_ACCESS_BINFO (*tp)));
WALK_SUBTREE (BASELINK_FUNCTIONS (*tp));
*walk_subtrees_p = 0;
break;