Get rid of PostfixExpressionAST and store the base expression together with the PostfixAST nodes.

This commit is contained in:
Roberto Raggi
2010-06-23 14:38:41 +02:00
parent ed2862acce
commit da817310c2
19 changed files with 136 additions and 235 deletions

View File

@@ -346,15 +346,11 @@ protected:
return false;
}
virtual bool visit(PostfixExpressionAST *ast)
virtual bool visit(MemberAccessAST *ast)
{
// accept only the base expression
accept(ast->base_expression);
for (PostfixListAST *it = ast->postfix_expression_list; it; it = it->next) {
PostfixAST *fx = it->value;
if (fx->asMemberAccess() != 0)
continue; // skip members
accept(fx);
}
// and ignore the member name.
return false;
}