In the attached code partial specialization of struct apply in struct METAFUNCTION2 should be rejected according to C++ Standard 14.7.3/3: A declaration of a function template or class template being explicitly specialized shall be in scope at the point of declaration of an explicit specialization. What's more troublesome is a fact that specialization in METAFUNCTION2 seems to affect the template in METAFUNCTION. The program produces: int double double while I would expect: int HELPER<float, double> double
Created attachment 18568 [details] the offending code
Fixed for 4.5.0, not a regression, closing as fixed.