зеркало из https://github.com/microsoft/clang-1.git
move the check into MarkNoReturnFunction.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@80980 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Родитель
326d6176ae
Коммит
4e71ddb873
|
@ -1420,6 +1420,9 @@ static bool EvalOSAtomic(ExplodedNodeSet& Dst,
|
|||
static void MarkNoReturnFunction(const FunctionDecl *FD, CallExpr *CE,
|
||||
const GRState *state,
|
||||
GRStmtNodeBuilder *Builder) {
|
||||
if (!FD)
|
||||
return;
|
||||
|
||||
if (FD->getAttr<NoReturnAttr>() ||
|
||||
FD->getAttr<AnalyzerNoReturnAttr>())
|
||||
Builder->BuildSinks = true;
|
||||
|
@ -1580,8 +1583,8 @@ void GRExprEngine::VisitCallRec(CallExpr* CE, ExplodedNode* Pred,
|
|||
|
||||
SaveAndRestore<bool> OldSink(Builder->BuildSinks);
|
||||
const FunctionDecl* FD = L.getAsFunctionDecl();
|
||||
if (FD)
|
||||
MarkNoReturnFunction(FD, CE, state, Builder);
|
||||
|
||||
MarkNoReturnFunction(FD, CE, state, Builder);
|
||||
|
||||
// Evaluate the call.
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче