Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / clang / test / ASTMerge / class-template-partial-spec / Inputs / class-template-partial-spec2.cpp
blob2f3f0c68e28c6ffe0828abcdcf1f1ce0ce9cb370
1 template<typename T, typename P>
2 struct TwoOptionTemplate {};
4 template<typename T>
5 struct TwoOptionTemplate<T, char> {
6 int member;
7 };
10 template<typename T>
11 struct TwoOptionTemplate<T, double> {
12 float member;
15 template<typename T>
16 struct TwoOptionTemplate<T, T> {
17 T** member;
20 TwoOptionTemplate<int, char> X0;
21 TwoOptionTemplate<int, double> X1;
22 TwoOptionTemplate<void *, wchar_t> X2;
23 TwoOptionTemplate<long, long> X3;
24 TwoOptionTemplate<int, int> X4;
25 TwoOptionTemplate<long, long> SingleDest;
26 TwoOptionTemplate<int, double> SecondDoubleDest;
29 template<int I, class C>
30 struct IntTemplateSpec {};
32 template<class C>
33 struct IntTemplateSpec<4, C> {
34 C member;
37 template<int I>
38 struct IntTemplateSpec<I, void *> {
39 double member;
40 static constexpr int val = I;
43 template<int I>
44 struct IntTemplateSpec<I, double> {
45 char member;
46 static constexpr int val = I;
49 IntTemplateSpec<4, wchar_t>Y0;
50 IntTemplateSpec<5, void *> Y1;
51 IntTemplateSpec<1, int> Y2;
52 IntTemplateSpec<2, int> Y3;
53 IntTemplateSpec<43, double> NumberDest;
55 namespace One {
56 namespace Two {
57 namespace Three {
59 template<class T>
60 class Parent {};
62 } // namespace Three
64 } // namespace Two
66 template<typename T, typename X>
67 struct Child1: public Two::Three::Parent<unsigned> {
68 char member;
71 template<class T>
72 struct Child1<T, One::Two::Three::Parent<T>> {
73 T member;
76 } // namespace One
78 namespace Dst { One::Child1<double, One::Two::Three::Parent<double>> Z0Dst; }
79 One::Child1<int, float> Z1;