diff options
| author | Dimitry Andric <dim@FreeBSD.org> | 2012-08-19 10:33:04 +0000 |
|---|---|---|
| committer | Dimitry Andric <dim@FreeBSD.org> | 2012-08-19 10:33:04 +0000 |
| commit | 657bc3d9848e3be92029b2416031340988cd0111 (patch) | |
| tree | 5b9c2fa9d79942fbdce3d618e37e27c18263af9a /lib/Sema/SemaExpr.cpp | |
| parent | 56d91b49b13fe55c918afbda19f6165b5fbff87a (diff) | |
Notes
Diffstat (limited to 'lib/Sema/SemaExpr.cpp')
| -rw-r--r-- | lib/Sema/SemaExpr.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Sema/SemaExpr.cpp b/lib/Sema/SemaExpr.cpp index 6a503ee2d9b5..3875ba171366 100644 --- a/lib/Sema/SemaExpr.cpp +++ b/lib/Sema/SemaExpr.cpp @@ -9461,7 +9461,8 @@ ExprResult Sema::ActOnBlockStmtExpr(SourceLocation CaretLoc, // If needed, diagnose invalid gotos and switches in the block. if (getCurFunction()->NeedsScopeChecking() && - !hasAnyUnrecoverableErrorsInThisFunction()) + !hasAnyUnrecoverableErrorsInThisFunction() && + !PP.isCodeCompletionEnabled()) DiagnoseInvalidJumps(cast<CompoundStmt>(Body)); BSI->TheDecl->setBody(cast<CompoundStmt>(Body)); |
