Created attachment 44772 [details] Example code, which should be rejected In the attached example, a base class is defined with a member function template and a derived class is defined with the same member function template. Both member function templates have the same parameter list but are SFINAE'd with exclusive conditions. However, according to http://eel.is/c++draft/namespace.udecl#1 hidden functions shall not participate in the name lookup and the base function template is hidden according to http://eel.is/c++draft/namespace.udecl#15. Therefore, the example code should be rejected, but it compiles without warnings. The issue came up on this stackoverflow question: https://stackoverflow.com/questions/52590220/name-lookup-error-of-enable-ifd-inherited-member-functions
Confirmed, not a regression. Reduced: template<typename> struct is_int { }; template<> struct is_int<int> { using type = void; }; class MyTag {}; template<typename> struct is_tag { }; template<> struct is_tag<MyTag> { using type = void; }; struct Base { template <typename RType> typename is_int<RType>::type create(RType) { } }; struct Derived : Base { using Base::create; template <typename Tag> typename is_tag<Tag>::type create(Tag) { } }; int main() { Derived d; d.create(MyTag()); d.create(0); }
Is this realy a bug or an other instance of core issue 1980: http://www.open-std.org/jtc1/sc22/wg21/docs/cwg_active.html#1980. I think the behavior of Gcc is the one expected by the standardization commitee.
Yes, it's that issue again, thanks.