================ @@ -807,6 +808,65 @@ class ScalarExprEmitter : public StmtVisitor<ScalarExprEmitter, mlir::Value> { VISITCOMP(EQ) VISITCOMP(NE) #undef VISITCOMP + + mlir::Value VisitBinAssign(const BinaryOperator *e) { + const bool ignore = std::exchange(ignoreResultAssign, false); + + mlir::Value rhs; + LValue lhs; + + switch (e->getLHS()->getType().getObjCLifetime()) { ---------------- andykaylor wrote:
It's strange that this makes Objective C seem like the normal case. I would have expected something like `if (objC) { switch()...`. I found a couple of other places do something like `if (auto ownership = FQT.getObjCLifetime())` and then a switch like this. I wonder if that would result in better performance for the non-ObjectiveC path. https://github.com/llvm/llvm-project/pull/135115 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits