aaron.ballman added inline comments.

================
Comment at: clang/lib/Sema/SemaExpr.cpp:10244-10245
+  // This operation may not be performed on boolean vectors.
+  if (!AllowBoolOperation && (isBoolOrExtVectorBoolType(LHSType) &&
+                              isBoolOrExtVectorBoolType(RHSType)))
+    return ReportInvalid ? InvalidOperands(Loc, LHS, RHS) : QualType();
----------------
simoll wrote:
> aaron.ballman wrote:
> > No need for the parens, but should that `&&` have been `||`?
> The `&&` is intentional. We cannot step into this if `AllowBoolOperation` is 
> true.
Yes, but don't we want to step into it if *either* operand is a vector boolean 
type when bool operations are not allowed? (I'm confused by the 
`!AllowBoolOperations` but then allowing them anyway if only one operand is a 
vector bool.)


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D88905/new/

https://reviews.llvm.org/D88905

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to