gcc/testsuite/gnat.dg/specs/pack12.ads
raw| 1 | -- { dg-do compile } |
| 2 | -- { dg-options "-O2" } |
| 3 | |
| 4 | package Pack12 is |
| 5 | |
| 6 | type Rec1 is record |
| 7 | B : Boolean; |
| 8 | N : Natural; |
| 9 | end record; |
| 10 | |
| 11 | type Rec2 is record |
| 12 | B : Boolean; |
| 13 | R : Rec1; |
| 14 | end record; |
| 15 | pragma Pack (Rec2); |
| 16 | |
| 17 | type Rec3 is tagged record |
| 18 | R : Rec2; |
| 19 | end record; |
| 20 | |
| 21 | end Pack12; |