Lines Matching refs:Bop
14156 BinaryOperator *Bop) { in EmitDiagnosticForLogicalAndInLogicalOr() argument
14157 assert(Bop->getOpcode() == BO_LAnd); in EmitDiagnosticForLogicalAndInLogicalOr()
14158 Self.Diag(Bop->getOperatorLoc(), diag::warn_logical_and_in_logical_or) in EmitDiagnosticForLogicalAndInLogicalOr()
14159 << Bop->getSourceRange() << OpLoc; in EmitDiagnosticForLogicalAndInLogicalOr()
14160 SuggestParentheses(Self, Bop->getOperatorLoc(), in EmitDiagnosticForLogicalAndInLogicalOr()
14162 << Bop->getOpcodeStr(), in EmitDiagnosticForLogicalAndInLogicalOr()
14163 Bop->getSourceRange()); in EmitDiagnosticForLogicalAndInLogicalOr()
14185 if (BinaryOperator *Bop = dyn_cast<BinaryOperator>(LHSExpr)) { in DiagnoseLogicalAndInLogicalOrLHS() local
14186 if (Bop->getOpcode() == BO_LAnd) { in DiagnoseLogicalAndInLogicalOrLHS()
14191 if (!EvaluatesAsTrue(S, Bop->getLHS())) in DiagnoseLogicalAndInLogicalOrLHS()
14192 return EmitDiagnosticForLogicalAndInLogicalOr(S, OpLoc, Bop); in DiagnoseLogicalAndInLogicalOrLHS()
14193 } else if (Bop->getOpcode() == BO_LOr) { in DiagnoseLogicalAndInLogicalOrLHS()
14194 if (BinaryOperator *RBop = dyn_cast<BinaryOperator>(Bop->getRHS())) { in DiagnoseLogicalAndInLogicalOrLHS()
14207 if (BinaryOperator *Bop = dyn_cast<BinaryOperator>(RHSExpr)) { in DiagnoseLogicalAndInLogicalOrRHS() local
14208 if (Bop->getOpcode() == BO_LAnd) { in DiagnoseLogicalAndInLogicalOrRHS()
14213 if (!EvaluatesAsTrue(S, Bop->getRHS())) in DiagnoseLogicalAndInLogicalOrRHS()
14214 return EmitDiagnosticForLogicalAndInLogicalOr(S, OpLoc, Bop); in DiagnoseLogicalAndInLogicalOrRHS()
14224 if (BinaryOperator *Bop = dyn_cast<BinaryOperator>(SubExpr)) { in DiagnoseBitwiseOpInBitwiseOp() local
14225 if (Bop->isBitwiseOp() && Bop->getOpcode() < Opc) { in DiagnoseBitwiseOpInBitwiseOp()
14226 S.Diag(Bop->getOperatorLoc(), diag::warn_bitwise_op_in_bitwise_op) in DiagnoseBitwiseOpInBitwiseOp()
14227 << Bop->getOpcodeStr() << BinaryOperator::getOpcodeStr(Opc) in DiagnoseBitwiseOpInBitwiseOp()
14228 << Bop->getSourceRange() << OpLoc; in DiagnoseBitwiseOpInBitwiseOp()
14229 SuggestParentheses(S, Bop->getOperatorLoc(), in DiagnoseBitwiseOpInBitwiseOp()
14231 << Bop->getOpcodeStr(), in DiagnoseBitwiseOpInBitwiseOp()
14232 Bop->getSourceRange()); in DiagnoseBitwiseOpInBitwiseOp()
14239 if (BinaryOperator *Bop = dyn_cast<BinaryOperator>(SubExpr)) { in DiagnoseAdditionInShift() local
14240 if (Bop->getOpcode() == BO_Add || Bop->getOpcode() == BO_Sub) { in DiagnoseAdditionInShift()
14241 StringRef Op = Bop->getOpcodeStr(); in DiagnoseAdditionInShift()
14242 S.Diag(Bop->getOperatorLoc(), diag::warn_addition_in_bitshift) in DiagnoseAdditionInShift()
14243 << Bop->getSourceRange() << OpLoc << Shift << Op; in DiagnoseAdditionInShift()
14244 SuggestParentheses(S, Bop->getOperatorLoc(), in DiagnoseAdditionInShift()
14246 Bop->getSourceRange()); in DiagnoseAdditionInShift()