// { dg-do compile } // Contributed by: // PR c++/14389: Disambiguate overloaded member templates which differ only // in the template argument list. namespace N1 { struct S { template< typename B, typename A > void foo(); template< typename A > void foo(); }; template< typename A > void S::foo() {} template< typename B, typename A > void S::foo() {} template void S::foo (); template void S::foo (); } namespace N2 { struct S { template< typename _A > void foo(); template< int _i > void foo(); }; template< typename _A > void S::foo() {} template void S::foo< 0 >(); // { dg-error "no definition available" "no def" } // { dg-message "instantiated" "instantiated" { target *-*-* } 30 } }