Debian Codegraph @

gcc/testsuite/gnat.dg/discr21_pkg.ads

raw
1 package Discr21_Pkg is
2
3 type Position is record
4 x,y,z : Float;
5 end record;
6
7 type Dim is (Two, Three);
8
9 type VPosition (D: Dim := Three) is record
10 x, y : Float;
11 case D is
12 when Two => null;
13 when Three => z : Float;
14 end case;
15 end record;
16
17 function To_Position (x, y, z : Float) return VPosition;
18
19 end Discr21_Pkg;