diff options
author | Erik Verbruggen <erik.verbruggen@nokia.com> | 2010-06-18 09:08:00 +0200 |
---|---|---|
committer | Erik Verbruggen <erik.verbruggen@nokia.com> | 2010-06-18 09:10:11 +0200 |
commit | 3c3af9c25b6e57dfc8c28a07679b90f902759a1a (patch) | |
tree | 09f637e73c510a3ba57a7aa4b9437a58573a61e7 /src/shared/cplusplus/CheckDeclaration.cpp | |
parent | a1a565b9c55b563460be0d5ca7aef6deb93e0ed1 (diff) | |
download | qt-creator-3c3af9c25b6e57dfc8c28a07679b90f902759a1a.tar.gz |
Fixed return-type checking for ObjC methods.
Diffstat (limited to 'src/shared/cplusplus/CheckDeclaration.cpp')
-rw-r--r-- | src/shared/cplusplus/CheckDeclaration.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/shared/cplusplus/CheckDeclaration.cpp b/src/shared/cplusplus/CheckDeclaration.cpp index a0ae84fa5a..d38aa0eeee 100644 --- a/src/shared/cplusplus/CheckDeclaration.cpp +++ b/src/shared/cplusplus/CheckDeclaration.cpp @@ -720,10 +720,6 @@ bool CheckDeclaration::visit(ObjCMethodDeclarationAST *ast) Symbol *symbol; if (ast->function_body) { - if (!semantic()->skipFunctionBodies()) { - semantic()->check(ast->function_body, methodTy->members()); - } - symbol = methodTy; } else { Declaration *decl = control()->newDeclaration(selector->firstToken(), methodTy->name()); @@ -742,6 +738,10 @@ bool CheckDeclaration::visit(ObjCMethodDeclarationAST *ast) _scope->enterSymbol(symbol); + if (ast->function_body && !semantic()->skipFunctionBodies()) { + semantic()->check(ast->function_body, methodTy->members()); + } + return false; } |