summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gnat.dg/discr1.ads
blob: e2adab4412c5bb3acae65414343e1b836daab729 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
package discr1 is

  type R is (One, Two);

  type C_Type (Kind : R) is
  record
    case Kind is
      when One =>
        Name       : Integer;
      when Two =>
        Designator : String (1 .. 40);
    end case;
  end record;
  
  for C_Type use record
    Name        at   0 range 0.. 31;
    Designator  at   0 range 0..319;
    Kind        at  40 range 0..  7;
  end record;
  
  for C_Type'Size use 44 * 8;
  
  procedure Assign (Id : String);

end discr1;