gcc/testsuite/gnat.dg/addr10.adb
raw| 1 | -- { dg-do compile } |
| 2 | |
| 3 | with System; |
| 4 | |
| 5 | procedure Addr10 is |
| 6 | type Limited_Type is limited record |
| 7 | Element : Integer; |
| 8 | end record; |
| 9 | |
| 10 | function Initial_State return Limited_Type is ((Element => 0)); |
| 11 | |
| 12 | type Double_Limited_Type is |
| 13 | record |
| 14 | A : Limited_Type; |
| 15 | end record; |
| 16 | |
| 17 | Double_Limited : Double_Limited_Type := |
| 18 | (A => Initial_State) |
| 19 | with |
| 20 | Volatile, |
| 21 | Address => System'To_Address (16#1234_5678#); |
| 22 | begin |
| 23 | null; |
| 24 | end Addr10; |