diff options
author | hjk <qtc-committer@nokia.com> | 2009-02-09 17:11:23 +0100 |
---|---|---|
committer | hjk <qtc-committer@nokia.com> | 2009-02-09 17:11:23 +0100 |
commit | ce22a96041ed7a61b09ea9596f415d30d67e68f1 (patch) | |
tree | 3469ec74c2bd7b928354fda9abdb9fe3d33639d8 /src/shared/cplusplus/CheckStatement.cpp | |
parent | 65638f7cc2c60b9ae8ece542f5e262268ef22577 (diff) | |
parent | 17d047ced8966bb377a0937a35ab299f86e654a6 (diff) | |
download | qt-creator-ce22a96041ed7a61b09ea9596f415d30d67e68f1.tar.gz |
Merge branch 'master' of git@scm.dev.nokia.troll.no:creator/mainline
Diffstat (limited to 'src/shared/cplusplus/CheckStatement.cpp')
-rw-r--r-- | src/shared/cplusplus/CheckStatement.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/shared/cplusplus/CheckStatement.cpp b/src/shared/cplusplus/CheckStatement.cpp index 67902ff252..4c51bc19bd 100644 --- a/src/shared/cplusplus/CheckStatement.cpp +++ b/src/shared/cplusplus/CheckStatement.cpp @@ -103,6 +103,7 @@ bool CheckStatement::visit(CaseStatementAST *ast) bool CheckStatement::visit(CompoundStatementAST *ast) { Block *block = control()->newBlock(ast->lbrace_token); + ast->symbol = block; _scope->enterSymbol(block); Scope *previousScope = switchScope(block->members()); for (StatementAST *it = ast->statements; it; it = it->next) { @@ -145,6 +146,7 @@ bool CheckStatement::visit(ExpressionStatementAST *ast) bool CheckStatement::visit(ForStatementAST *ast) { Block *block = control()->newBlock(ast->for_token); + ast->symbol = block; _scope->enterSymbol(block); Scope *previousScope = switchScope(block->members()); semantic()->check(ast->initializer, _scope); @@ -158,6 +160,7 @@ bool CheckStatement::visit(ForStatementAST *ast) bool CheckStatement::visit(IfStatementAST *ast) { Block *block = control()->newBlock(ast->if_token); + ast->symbol = block; _scope->enterSymbol(block); Scope *previousScope = switchScope(block->members()); FullySpecifiedType exprTy = semantic()->check(ast->condition, _scope); @@ -197,6 +200,7 @@ bool CheckStatement::visit(ReturnStatementAST *ast) bool CheckStatement::visit(SwitchStatementAST *ast) { Block *block = control()->newBlock(ast->switch_token); + ast->symbol = block; _scope->enterSymbol(block); Scope *previousScope = switchScope(block->members()); FullySpecifiedType condTy = semantic()->check(ast->condition, _scope); @@ -217,6 +221,7 @@ bool CheckStatement::visit(TryBlockStatementAST *ast) bool CheckStatement::visit(CatchClauseAST *ast) { Block *block = control()->newBlock(ast->catch_token); + ast->symbol = block; _scope->enterSymbol(block); Scope *previousScope = switchScope(block->members()); semantic()->check(ast->exception_declaration, _scope); @@ -228,6 +233,7 @@ bool CheckStatement::visit(CatchClauseAST *ast) bool CheckStatement::visit(WhileStatementAST *ast) { Block *block = control()->newBlock(ast->while_token); + ast->symbol = block; _scope->enterSymbol(block); Scope *previousScope = switchScope(block->members()); FullySpecifiedType condTy = semantic()->check(ast->condition, _scope); |