summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gnat.dg/storage_size1.adb
blob: 970caf1615613898378d4f6e6e14eb72d694413d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
--  { dg-do compile }

with Ada.Text_IO; with Ada.Integer_Text_IO;

procedure Storage_Size1 is

  package O renames Ada.Text_IO;
  package T renames Ada.Integer_Text_IO;

  type Struct is record first, second: Integer; end record;

  type SP is access Struct
      with Storage_Size => 64 * Struct'Max_Size_In_Storage_Elements;

begin

  T.Put(SP'Storage_Size); O.New_Line(1);

end Storage_Size1;