testsuite/small/record-nested-2.c
raw| 1 | /* { dg-options "-DCE_EXTRACT_FUNCTIONS=Get_X -DCE_NO_EXTERNALIZATION" }*/ |
| 2 | struct Z { |
| 3 | int z; |
| 4 | }; |
| 5 | |
| 6 | typedef struct Z Z; |
| 7 | |
| 8 | struct Point |
| 9 | { |
| 10 | int x, y; |
| 11 | Z *z; |
| 12 | }; |
| 13 | |
| 14 | int Get_X(struct Point *p) |
| 15 | { |
| 16 | return p->x; |
| 17 | } |
| 18 | |
| 19 | /* { dg-final { scan-tree-dump "struct Z;" } } */ |
| 20 | /* { dg-final { scan-tree-dump "typedef struct Z Z;" } } */ |
| 21 | /* { dg-final { scan-tree-dump "struct Point\n{\n *int x, y;\n *Z \*z;\n};" } } */ |
| 22 | /* { dg-final { scan-tree-dump "int Get_X" } } */ |