Lines Matching defs:SExpr

50 /// SExpr implements a simple expression language that is used to store,
51 /// compare, and pretty-print C++ expressions. Unlike a clang Expr, a SExpr
71 class SExpr {
186 // A SExpr is a list of SExprNodes in prefix order. The Size field allows
274 /// Build an SExpr from the given C++ expression.
276 /// Note: this function merely creates a SExpr; it does not check to
467 /// \brief Construct a SExpr from an expression.
547 explicit SExpr(clang::Decl::EmptyShell e) { NodeVec.clear(); }
554 SExpr(const Expr* MutexExp, const Expr *DeclExp, const NamedDecl* D,
589 bool operator==(const SExpr &other) const {
593 bool operator!=(const SExpr &other) const {
597 bool matches(const SExpr &Other, unsigned i = 0, unsigned j = 0) const {
617 bool partiallyMatches(const SExpr &Other) const {
722 class MutexIDList : public SmallVector<SExpr, 3> {
724 /// \brief Return true if the list contains the specified SExpr
726 bool contains(const SExpr& M) {
733 void push_back_nodup(const SExpr& M) {
756 SExpr UnderlyingMutex; // for ScopedLockable objects
764 LockData(SourceLocation AcquireLoc, LockKind LKind, const SExpr &Mu)
792 SExpr MutID;
795 FactEntry(const SExpr& M, const LockData& L)
810 FactID newLock(const SExpr& M, const LockData& L) {
845 FactID addLock(FactManager& FM, const SExpr& M, const LockData& L) {
851 bool removeLock(FactManager& FM, const SExpr& M) {
871 iterator findLockIter(FactManager &FM, const SExpr &M) {
873 const SExpr &Exp = FM[*I].MutID;
880 LockData* findLock(FactManager &FM, const SExpr &M) const {
882 const SExpr &Exp = FM[*I].MutID;
889 LockData* findLockUniv(FactManager &FM, const SExpr &M) const {
891 const SExpr &Exp = FM[*I].MutID;
898 FactEntry* findPartialMatch(FactManager &FM, const SExpr &M) const {
900 const SExpr& Exp = FM[*I].MutID;
909 /// A Lockset maps each SExpr (defined above) to information about how it has
911 typedef llvm::ImmutableMap<SExpr, LockData> Lockset;
1453 void addLock(FactSet &FSet, const SExpr &Mutex, const LockData &LDat);
1454 void removeLock(FactSet &FSet, const SExpr &Mutex,
1492 void ThreadSafetyAnalyzer::addLock(FactSet &FSet, const SExpr &Mutex,
1512 const SExpr &Mutex,
1556 SExpr Mu(0, Exp, D, SelfDecl);
1558 SExpr::warnInvalidLock(Handler, 0, Exp, D);
1565 SExpr Mu(*I, Exp, D, SelfDecl);
1567 SExpr::warnInvalidLock(Handler, *I, Exp, D);
1814 SExpr Mutex(MutexExp, Exp, D);
1816 SExpr::warnInvalidLock(Analyzer->Handler, MutexExp, Exp, D);
1850 SExpr Mutex(MutexExp, Exp, D);
1852 SExpr::warnInvalidLock(Analyzer->Handler, MutexExp, Exp, D);
2077 SExpr SMutex(&DRE, 0, 0);
2250 const SExpr &FSet2Mutex = FactMan[*I].MutID;
2290 const SExpr &FSet1Mutex = FactMan[*I].MutID;