1 // Ensure that different pointer / reference types are considered genuinely
2 // different in --leaf-changes-only mode.
3 struct foo {
4 long z; // was int
5 };
6
7 struct ops1 {
8 int ** x; // was *
9 };
10
11 struct ops2 {
12 // A change to foo's size (impacting y's size) is currently considered local
13 // here. Arguably this should be considered non-local as the change to foo is
14 // also being reported independently. If this happens, the test case will
15 // need to be updated (to remove the reporting of the ops2 diff).
16 foo y[10];
17 };
18
19 struct ops3 {
20 void (*spong)(int && wibble); // was &
21 };
22
23 struct ops4 {
24 int & x; // was *
25 };
26
27 struct ops5 {
28 int *** x; // was *
29 };
30
31 // TODO: This *should* be considered a local change, but currently is not.
32 int var6[5][2]; // was [2][5]
33
register_ops1(ops1 *)34 void register_ops1(ops1*) { }
register_ops2(ops2 *)35 void register_ops2(ops2*) { }
register_ops3(ops3 *)36 void register_ops3(ops3*) { }
register_ops4(ops4 *)37 void register_ops4(ops4*) { }
register_ops5(ops5 *)38 void register_ops5(ops5*) { }
39