]> granicus.if.org Git - clang/commitdiff
In GRExprEngine treat @throw as an 'abort' that ends the current path. This is a...
authorTed Kremenek <kremenek@apple.com>
Tue, 9 Dec 2008 20:18:58 +0000 (20:18 +0000)
committerTed Kremenek <kremenek@apple.com>
Tue, 9 Dec 2008 20:18:58 +0000 (20:18 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@60789 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Analysis/GRExprEngine.cpp

index 343ac697a30278fcb3359eae54c2b0ff14ff787b..96776b46ff8ff88883a771246c7e1ebc0271c173 100644 (file)
@@ -377,6 +377,15 @@ void GRExprEngine::Visit(Stmt* S, NodeTy* Pred, NodeSet& Dst) {
       break;
     }
       
+    case Stmt::ObjCAtThrowStmtClass: {
+      // FIXME: This is not complete.  We basically treat @throw as
+      // an abort.
+      SaveAndRestore<bool> OldSink(Builder->BuildSinks);
+      Builder->BuildSinks = true;
+      MakeNode(Dst, S, Pred, GetState(Pred));
+      break;
+    }
+      
     case Stmt::ParenExprClass:
       Visit(cast<ParenExpr>(S)->getSubExpr()->IgnoreParens(), Pred, Dst);
       break;