1// PR c++/42608 2// { dg-do compile } 3 4template <class U, class V> 5struct A; 6 7template <class V> 8struct A<int, V> 9{ 10 void f (); 11}; 12 13template struct A<int, int>; 14 15int 16main () 17{ 18 A<int, int> a; 19 a.f (); 20 return 0; 21} 22 23// Make sure we get undefined reference error if 24// A<int, int>::f () isn't instantiated elsewhere. 25// { dg-final { scan-assembler-not "weak\[\n\t\]*_ZN1AIiiE1fEv" } } 26