================
@@ -10685,6 +10724,7 @@ QualType Sema::CheckMultiplyDivideOperands(ExprResult
&LHS, ExprResult &RHS,
if (compType.isNull() || !compType->isArithmeticType())
return InvalidOperands(Loc, LHS, RHS);
if (IsDiv) {
+ DetectPrecisionLossInComplexDivision(*this, RHS.get()->getType(), Loc);
----------------
Maetveis wrote:
The dividend is not relevant assuming its a built-in arithmetic type, which I
think it must be at this point in the code already. I'll try verifying this
assumption though. Note that IIUC the types have "usual arithmetic conversions"
applied to them here.
Whether the dividend is real or complex does not matter because complex divided
by complex and real divided by complex both need promotion, but neither complex
by complex (because it is elementwise) or real by real do.
https://github.com/llvm/llvm-project/pull/131477
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits