Process the translation unit.

This commit is contained in:
Roberto Raggi
2010-08-12 18:08:03 +02:00
parent 6321ccee9e
commit db5a61d3cf

View File

@@ -704,9 +704,12 @@ void Bind::translationUnit(TranslationUnitAST *ast)
if (! ast) if (! ast)
return; return;
Namespace *globalNamespace = control()->newNamespace(0, 0);
Scope *previousScope = switchScope(globalNamespace);
for (DeclarationListAST *it = ast->declaration_list; it; it = it->next) { for (DeclarationListAST *it = ast->declaration_list; it; it = it->next) {
this->declaration(it->value); this->declaration(it->value);
} }
(void) switchScope(previousScope);
} }
bool Bind::visit(ObjCProtocolRefsAST *ast) bool Bind::visit(ObjCProtocolRefsAST *ast)