1 struct anonymous_nest {
2   struct {
3     struct {
4       int a;
5       int b;
6     }; // anonymous
7     struct {
8       int c;
9       int d;
10     } foo;
11   }; // anonymous
12 };
13 
14 struct anonymous_child {
15   struct {
16     struct {
17       int a;
18       int b;
19     } grandchild;
20     struct {
21       int c;
22       int d;
23     } foo;
24   }; // anonymous
25 };
26 
27 struct anonymous_grandchild {
28   struct {
29     struct {
30       int a;
31       int b;
32     }; // anonymous
33     struct {
34       int c;
35       int d;
36     } foo;
37   } child;
38 };
39 
processor_nest(struct anonymous_nest * n)40 int processor_nest (struct anonymous_nest *n)
41 {
42   return n->foo.d + n->b; // Set breakpoint 0 here.
43 }
44 
processor_child(struct anonymous_child * c)45 int processor_child (struct anonymous_child *c)
46 {
47   return c->foo.d + c->grandchild.b; // Set breakpoint 1 here.
48 }
49 
processor_grandchild(struct anonymous_grandchild * g)50 int processor_grandchild (struct anonymous_grandchild *g)
51 {
52   return g->child.foo.d + g->child.b;
53 }
54 
55 
56 
57 typedef struct {
58     int dummy;
59 } type_y;
60 
61 typedef struct {
62     type_y y;
63 } type_z;
64 
65 
66 
main()67 int main()
68 {
69   struct anonymous_nest n = { 0, 2, 0, 4 };
70   struct anonymous_child c = { 0, 2, 0, 4 };
71   struct anonymous_grandchild g = { 0, 2, 0, 4 };
72   type_z *pz = 0;
73   type_z z = {{2}};
74 
75   processor_nest(&n);
76   processor_child(&c);
77   processor_grandchild(&g); // Set breakpoint 2 here.
78 
79   return 0;
80 }
81