[clang] [MS][clang] Add support for vector deleting destructors (PR #126240)
Mariya Podchishchaeva via cfe-commits
cfe-commits at lists.llvm.org
Fri Feb 21 02:04:07 PST 2025
================
@@ -7919,3 +7919,38 @@ void CodeGenModule::moveLazyEmissionStates(CodeGenModule *NewBuilder) {
NewBuilder->ABI->MangleCtx = std::move(ABI->MangleCtx);
}
+
+bool CodeGenModule::classNeedsVectorDestructor(const CXXRecordDecl *RD) {
+ CXXDestructorDecl *Dtor = RD->getDestructor();
+ if (Dtor && Dtor->isVirtual() && Dtor->isDefined() &&
+ Dtor->hasAttr<DLLExportAttr>())
+ return true;
+
+ assert(getCXXABI().hasVectorDeletingDtors());
+ return RequireVectorDeletingDtor.count(RD);
+}
+
+void CodeGenModule::requireVectorDestructorDefinition(const CXXRecordDecl *RD) {
----------------
Fznamznon wrote:
Agree, added the comment trying to explain.
https://github.com/llvm/llvm-project/pull/126240
More information about the cfe-commits
mailing list