================ @@ -3102,11 +3103,15 @@ void CXXNameMangler::mangleType(QualType T) { addSubstitution(T); } -void CXXNameMangler::mangleCXXRecordDecl(const CXXRecordDecl *Record) { +void CXXNameMangler::mangleCXXRecordDecl(const CXXRecordDecl *Record, + bool IsManglingVTable) { if (mangleSubstitution(Record)) return; mangleName(Record); - if (isCompatibleWith(LangOptions::ClangABI::Ver19)) + // If we are mangling vtables, return early without adding the record to the + // dictionary of substitution candidates to maintain compatibility with older + // ABIs. + if (IsManglingVTable && isCompatibleWith(LangOptions::ClangABI::Ver19)) ---------------- mizvekov wrote:
So the previous buggy behavior is a bit interesting. You are saying we used to mangle a substitution here, but not actually consider this site a user of the type for future substitutions? Do you have a specific test case for that? https://github.com/llvm/llvm-project/pull/138947 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits