[clang] [CIR] Add initial support for operator delete (PR #160574)
    Andy Kaylor via cfe-commits 
    cfe-commits at lists.llvm.org
       
    Wed Sep 24 11:05:23 PDT 2025
    
    
  
================
@@ -210,6 +210,60 @@ RValue CIRGenFunction::emitCXXMemberOrOperatorCall(
   return emitCall(fnInfo, callee, returnValue, args, nullptr, loc);
 }
 
+namespace {
+/// The parameters to pass to a usual operator delete.
+struct UsualDeleteParams {
+  TypeAwareAllocationMode typeAwareDelete = TypeAwareAllocationMode::No;
+  bool destroyingDelete = false;
+  bool size = false;
+  AlignedAllocationMode alignment = AlignedAllocationMode::No;
+};
+} // namespace
+
+// FIXME(cir): this should be shared with LLVM codegen
----------------
andykaylor wrote:
I've created https://github.com/llvm/llvm-project/pull/160554 to refactor this for sharing. If that's accepted before this PR lands, I'll update this here. Otherwise, I'll do that as a follow-up.
https://github.com/llvm/llvm-project/pull/160574
    
    
More information about the cfe-commits
mailing list