The following is invalid code and should be rejected: class foo { int mf(int); int mf(); };
template<int (foo::*)()> struct fm_obj { }; fm_obj<&foo::mf> a; -- Summary: Accepts invalid, inaccessible overloaded function is accepted Product: gcc Version: 4.1.0 Status: UNCONFIRMED Keywords: accepts-invalid Severity: normal Priority: P2 Component: c++ AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: pinskia at gcc dot gnu dot org CC: gcc-bugs at gcc dot gnu dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=22620