Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / clang / test / Modules / Inputs / merge-using-decls / b.h
blobbe9bf240ccebfcc2879f19a273845bcbddc94fba
1 struct X {
2 int v;
3 typedef int t;
4 void f(X);
5 };
7 struct YB {
8 typedef YB Y;
9 int value;
10 typedef int type;
13 struct YBRev {
14 typedef int value;
15 int type;
18 struct Z {
19 void f(Z);
22 template<typename T> struct C : X, T {
23 using T::value;
24 using typename T::type;
25 using X::v;
26 using typename X::t;
29 template<typename T> struct D : X, T {
30 // Mismatch in type/non-type-ness.
31 using typename T::value;
32 using T::type;
33 using X::v;
34 using typename X::t;
37 #if __cplusplus <= 199711L // C++11 does not allow access declarations
38 template<typename T> struct E : X, T {
39 // Mismatch in using/access-declaration-ness.
40 T::value;
41 X::v;
43 #endif
45 template<typename T> struct F : X, T {
46 // Mismatch in nested-name-specifier.
47 using T::Y::value;
48 using typename T::Y::type;
49 using ::X::v;
50 using typename ::X::t;
53 // Force instantiation.
54 typedef C<YB>::type I;
55 typedef D<YBRev>::t I;
57 #if __cplusplus <= 199711L // C++11 does not allow access declarations
58 typedef E<YB>::type I;
59 #endif
61 typedef F<YB>::type I;
63 #if __cplusplus >= 201702L
64 template<typename ...T> struct G : T... {
65 using T::f...;
67 using Q = decltype(G<X, Z>());
68 #endif