aboutsummaryrefslogtreecommitdiff
path: root/lib/Sema/SemaExpr.cpp
diff options
context:
space:
mode:
authorTed Kremenek <kremenek@apple.com>2010-03-23 00:13:23 +0000
committerTed Kremenek <kremenek@apple.com>2010-03-23 00:13:23 +0000
commitd064fdc4b7b64ca55b40b70490c79d6f569df78e (patch)
tree07a0c6fb87b558bbfb070a1aba01717486b9fe47 /lib/Sema/SemaExpr.cpp
parent22f757b38da3fc9f17ea9e99524064fdfbca3456 (diff)
Only perform CFG-based warnings on 'static inline' functions that
are called (transitively) by regular functions/blocks within a translation untion. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@99233 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaExpr.cpp')
-rw-r--r--lib/Sema/SemaExpr.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/Sema/SemaExpr.cpp b/lib/Sema/SemaExpr.cpp
index 007d625b41..97f520d86f 100644
--- a/lib/Sema/SemaExpr.cpp
+++ b/lib/Sema/SemaExpr.cpp
@@ -7012,8 +7012,9 @@ Sema::OwningExprResult Sema::ActOnBlockStmtExpr(SourceLocation CaretLoc,
}
// Issue any analysis-based warnings.
- sema::AnalysisBasedWarnings W(*this);
- W.IssueWarnings(BSI->TheDecl, BlockTy);
+ const sema::AnalysisBasedWarnings::Policy &WP =
+ AnalysisWarnings.getDefaultPolicy();
+ AnalysisWarnings.IssueWarnings(WP, BSI->TheDecl, BlockTy);
Expr *Result = new (Context) BlockExpr(BSI->TheDecl, BlockTy,
BSI->hasBlockDeclRefExprs);