diff options
Diffstat (limited to 'include/clang/Analysis/ProgramEdge.h')
-rw-r--r-- | include/clang/Analysis/ProgramEdge.h | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/include/clang/Analysis/ProgramEdge.h b/include/clang/Analysis/ProgramEdge.h index ee8fae0140..1c10196c28 100644 --- a/include/clang/Analysis/ProgramEdge.h +++ b/include/clang/Analysis/ProgramEdge.h @@ -28,7 +28,7 @@ class ProgramEdge { uintptr_t Src, Dst; public: enum EdgeKind { BExprBlk=0, BlkBExpr=1, BExprBExpr=2, BlkBlk=3, - BExprSExpr=4, SExprSExpr=5, SExprBExpr=6 }; + BExprSExpr=4, SExprSExpr=5, SExprBExpr=6, Infeasible=7 }; static bool classof(const ProgramEdge*) { return true; } @@ -155,7 +155,18 @@ public: return E->getKind() == BlkBlk; } }; - + +class InfeasibleEdge : public ProgramEdge { +public: + InfeasibleEdge(Stmt* S) : ProgramEdge(S,NULL,Infeasible) {} + + Stmt* getStmt() const { return reinterpret_cast<Stmt*>(RawSrc()); } + + static bool classof(const ProgramEdge* E) { + return E->getKind() == Infeasible; + } +}; + } // end namespace clang |