[PR c++/84702] ICE with default tmpl arg of overload set
[official-gcc.git] / gcc / testsuite / g++.dg / template / incomplete5.C
blob1bd21b95e8c5b45ef06e410f0dbbec29522ea9af
1 // PR c++/33501
2 // { dg-do compile }
4 class A;        // { dg-message "forward declaration" }
6 template <typename T> struct X
8   static int f (T);             // { dg-message "initializing" }
9   static const T &make ();
10   static const bool value = sizeof (f (make ())) == sizeof (int);       // { dg-error "invalid use of incomplete type" }
13 int
14 main ()
16   return X <A>::value;