[clang] [CIR] Add support for delete cleanup after new operators (PR #184707)

Andy Kaylor via cfe-commits cfe-commits at lists.llvm.org
Thu Mar 5 09:10:57 PST 2026


================
@@ -2563,14 +2563,15 @@ void cir::TernaryOp::build(
 
   // Get result type from whichever branch has a yield (the other may have
   // unreachable from a throw expression)
-  auto yield =
-      dyn_cast_or_null<cir::YieldOp>(trueRegion->back().getTerminator());
-  if (!yield)
+  cir::YieldOp yield;
----------------
andykaylor wrote:

Oops. I made this change locally to do a quick experiment while I was reviewing your patch and then forgot to undo it.

https://github.com/llvm/llvm-project/pull/184707


More information about the cfe-commits mailing list