================ @@ -2545,10 +2545,12 @@ ASTDeclReader::VisitClassTemplateSpecializationDeclImpl( } // Explicit info. - if (TypeSourceInfo *TyInfo = readTypeSourceInfo()) { - auto *ExplicitInfo = - new (C) ClassTemplateSpecializationDecl::ExplicitSpecializationInfo; - ExplicitInfo->TypeAsWritten = TyInfo; + if (Record.readBool()) { + // FIXME: We don't need to allocate this if ExternLoc and TemplateKeywordLoc ---------------- erichkeane wrote:
This serialization is not expected to be stable. Could we just change the 'serialization' order here to be `ExternLoc/TemplateKeywordLoc/TemplateArgsList` instead? That way we could test this 'fixme' that way (in both places!). Also likely value to extract this whole section into its own function so the two can use the 'same' implementation here. https://github.com/llvm/llvm-project/pull/81642 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits