Lines Matching refs:Cond
48 const Stmt *Cond, ASTContext *Context) { in isVarThatIsPossiblyChanged() argument
49 if (const auto *DRE = dyn_cast<DeclRefExpr>(Cond)) { in isVarThatIsPossiblyChanged()
65 ObjCIvarRefExpr, ObjCPropertyRefExpr, ObjCMessageExpr>(Cond)) { in isVarThatIsPossiblyChanged()
68 } else if (const auto *CE = dyn_cast<CastExpr>(Cond)) { in isVarThatIsPossiblyChanged()
86 const Stmt *Cond, ASTContext *Context) { in isAtLeastOneCondVarChanged() argument
87 if (isVarThatIsPossiblyChanged(Func, LoopStmt, Cond, Context)) in isAtLeastOneCondVarChanged()
90 for (const Stmt *Child : Cond->children()) { in isAtLeastOneCondVarChanged()
101 static std::string getCondVarNames(const Stmt *Cond) { in getCondVarNames() argument
102 if (const auto *DRE = dyn_cast<DeclRefExpr>(Cond)) { in getCondVarNames()
108 for (const Stmt *Child : Cond->children()) { in getCondVarNames()
120 static bool isKnownToHaveValue(const Expr &Cond, const ASTContext &Ctx, in isKnownToHaveValue() argument
122 if (Cond.isValueDependent()) { in isKnownToHaveValue()
123 if (const auto *BinOp = dyn_cast<BinaryOperator>(&Cond)) { in isKnownToHaveValue()
134 } else if (const auto *UnOp = dyn_cast<UnaryOperator>(&Cond)) { in isKnownToHaveValue()
137 } else if (const auto *Paren = dyn_cast<ParenExpr>(&Cond)) in isKnownToHaveValue()
139 else if (const auto *ImplCast = dyn_cast<ImplicitCastExpr>(&Cond)) in isKnownToHaveValue()
144 if (Cond.EvaluateAsBooleanCondition(Result, Ctx)) in isKnownToHaveValue()
163 const auto *Cond = Result.Nodes.getNodeAs<Expr>("condition"); in check() local
167 if (isKnownToHaveValue(*Cond, *Result.Context, false)) in check()
175 Cond = Init; in check()
183 if (isAtLeastOneCondVarChanged(Func, LoopStmt, Cond, Result.Context)) in check()
186 std::string CondVarNames = getCondVarNames(Cond); in check()