@@ -8987,8 +8987,7 @@ Sema::CheckSpecializationInstantiationRedecl(SourceLocation NewLoc,
89878987 // The declaration itself has not actually been instantiated, so it is
89888988 // still okay to specialize it.
89898989 StripImplicitInstantiation (
8990- PrevDecl,
8991- Context.getTargetInfo ().getTriple ().isWindowsGNUEnvironment ());
8990+ PrevDecl, Context.getTargetInfo ().getTriple ().isOSCygMing ());
89928991 return false ;
89938992 }
89948993 // Fall through
@@ -9855,7 +9854,7 @@ DeclResult Sema::ActOnExplicitInstantiation(
98559854 : TSK_ExplicitInstantiationDeclaration;
98569855
98579856 if (TSK == TSK_ExplicitInstantiationDeclaration &&
9858- !Context.getTargetInfo ().getTriple ().isWindowsGNUEnvironment ()) {
9857+ !Context.getTargetInfo ().getTriple ().isOSCygMing ()) {
98599858 // Check for dllexport class template instantiation declarations,
98609859 // except for MinGW mode.
98619860 for (const ParsedAttr &AL : Attr) {
@@ -9920,7 +9919,7 @@ DeclResult Sema::ActOnExplicitInstantiation(
99209919 = PrevDecl ? PrevDecl->getTemplateSpecializationKind () : TSK_Undeclared;
99219920
99229921 if (TSK == TSK_ExplicitInstantiationDefinition && PrevDecl != nullptr &&
9923- Context.getTargetInfo ().getTriple ().isWindowsGNUEnvironment ()) {
9922+ Context.getTargetInfo ().getTriple ().isOSCygMing ()) {
99249923 // Check for dllexport class template instantiation definitions in MinGW
99259924 // mode, if a previous declaration of the instantiation was seen.
99269925 for (const ParsedAttr &AL : Attr) {
@@ -10088,7 +10087,7 @@ DeclResult Sema::ActOnExplicitInstantiation(
1008810087 // In MinGW mode, export the template instantiation if the declaration
1008910088 // was marked dllexport.
1009010089 if (PrevDecl_TSK == TSK_ExplicitInstantiationDeclaration &&
10091- Context.getTargetInfo ().getTriple ().isWindowsGNUEnvironment () &&
10090+ Context.getTargetInfo ().getTriple ().isOSCygMing () &&
1009210091 PrevDecl->hasAttr <DLLExportAttr>()) {
1009310092 dllExportImportClassTemplateSpecialization (*this , Def);
1009410093 }
0 commit comments