summaryrefslogtreecommitdiff
path: root/src/shared/cplusplus
diff options
context:
space:
mode:
authorRoberto Raggi <roberto.raggi@nokia.com>2010-08-12 18:08:03 +0200
committerRoberto Raggi <roberto.raggi@nokia.com>2010-08-12 18:08:18 +0200
commitdb5a61d3cfc56b5517d587b1c3f032b4a68caa61 (patch)
tree5f232df97119ef7a68edcb837fffe7ff9016e8f5 /src/shared/cplusplus
parent6321ccee9e6ab3a1c2f25bec3c5f5b4066160955 (diff)
downloadqt-creator-db5a61d3cfc56b5517d587b1c3f032b4a68caa61.tar.gz
Process the translation unit.
Diffstat (limited to 'src/shared/cplusplus')
-rw-r--r--src/shared/cplusplus/Bind.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/shared/cplusplus/Bind.cpp b/src/shared/cplusplus/Bind.cpp
index 793c6f7242..93904688ac 100644
--- a/src/shared/cplusplus/Bind.cpp
+++ b/src/shared/cplusplus/Bind.cpp
@@ -704,9 +704,12 @@ void Bind::translationUnit(TranslationUnitAST *ast)
if (! ast)
return;
+ Namespace *globalNamespace = control()->newNamespace(0, 0);
+ Scope *previousScope = switchScope(globalNamespace);
for (DeclarationListAST *it = ast->declaration_list; it; it = it->next) {
this->declaration(it->value);
}
+ (void) switchScope(previousScope);
}
bool Bind::visit(ObjCProtocolRefsAST *ast)