[dsymutil] Refactor ODR uniquing tests to be more readable.
[oota-llvm.git] / test / tools / dsymutil / Inputs / odr-types.h
1 struct S {
2         int I;
3
4         void incr() __attribute__((always_inline)) { I++; }
5         void incr(int Add) __attribute__((always_inline)) { I += Add; }
6
7         typedef int SInt;
8
9         struct Nested {
10                 double D;
11
12                 template<typename T> void init(T Val) { D = double(Val); }
13         };
14
15         Nested D;
16
17 public:
18         int foo() { return I; }
19 };
20
21 typedef S AliasForS;
22
23 namespace N {
24 class C {
25         AliasForS S;
26 };
27 }
28
29 namespace N {
30 namespace N {
31 class C {
32         int S;
33 };
34 }
35 }
36
37 namespace {
38         class AnonC {
39         };
40 }
41
42 union U {
43         class C {} C;
44         struct S {} S;
45 };
46
47 inline int func() {
48         struct CInsideFunc { int i; };
49         auto functor = []() { CInsideFunc dummy; return dummy.i; };
50         return functor();
51 }