================ @@ -12490,6 +12499,17 @@ static void AnalyzeImplicitConversions( (BO->getOpcode() == BO_And ? "&&" : "||")); S.Diag(BO->getBeginLoc(), diag::note_cast_operand_to_int); } + } else if (BO->isCommaOp() && !S.getLangOpts().CPlusPlus) { + /// Analyze the given comma operator. The basic idea behind the analysis + /// is to analyze the left and right operands slightly differently. The + /// left operand needs to check whether the operand itself has an implicit + /// conversion, but not whether the left operand induces an implicit + /// conversion for the entire comma expression itself. This is similar to + /// how CheckConditionalOperand behaves; it's as-if the correct operand + /// were directly used for the implicit conversion check. + CheckCommaOperand(S, BO->getLHS(), T, BO->getOperatorLoc(), false); ---------------- erichkeane wrote:
```suggestion CheckCommaOperand(S, BO->getLHS(), T, BO->getOperatorLoc(), /*ExtraCheckForImplicitConversion=*/false); ``` https://github.com/llvm/llvm-project/pull/138752 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits