1// { dg-do run } 2// { dg-options "" } 3// Origin: Mark Mitchell <mark@codesourcery.com> 4 5template <class T> 6struct O { 7 typedef char X; 8}; 9 10template <class T> 11struct S { 12 typedef double X; 13 14 template <class U> 15 struct I : public O<U> { 16 static X x; 17 }; 18}; 19 20template <class T> 21template <class U> 22typename S<T>::X S<T>::I<U>::x; 23 24int main() 25{ 26 return sizeof (S<int>::I<double>::x) == 1; 27} 28