Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / clang / test / SemaTemplate / instantiate-partial-spec.cpp
blob1e820e411ae3ad46a4869e4a3d23516a09068825
1 // RUN: %clang_cc1 -std=c++1y -verify %s
2 // expected-no-diagnostics
4 template<typename T> struct A {
5 template<typename U> struct B;
6 template<typename U> struct B<U*>;
7 };
8 template<typename T> template<typename U> struct A<T>::B<U*> {};
9 template struct A<int>;
10 A<int>::B<int*> b;
13 template<typename T> struct B {
14 template<typename U> static const int var1;
15 template<typename U> static const int var1<U*>;
17 template<typename U> static const int var2;
19 template<typename T> template<typename U> const int B<T>::var1<U*> = 1;
20 template<typename T> template<typename U> const int B<T>::var2<U*> = 1;
21 template struct B<int>;
22 int b_test1[B<int>::var1<int*>];
23 int b_test2[B<int>::var2<int*>];