--  Syntax forms of Ada the parser takes (RM 2.4.1, 2.8, 3.6.1, 3.7.1, 4.5.7, 5.4): a
--  discriminant constraint with a choice list, a subtype indication with a range constraint
--  in an index constraint and as a case choice, a pragma before a case alternative, an
--  underscore in an exponent, and a conditional expression as an attribute's argument.
with Ada.Text_IO;
procedure Main is
   type Rec (D1, D2 : Integer) is record
      null;
   end record;
   R : constant Rec (D1 | D2 => 4) := (D1 => 4, D2 => 4);
   type Vector is array (Integer range <>) of Integer;
   V : constant Vector (Natural range 1 .. 3) := (others => 0);
   X : constant := 1E1_0;
   B : constant Boolean := True;
   N : constant Integer := 2;
begin
   case N is
      pragma List (On);
      when Natural range 1 .. 2 => Ada.Text_IO.Put_Line ("small" & Integer'Image (V'Length));
      when others => null;
   end case;
   Ada.Text_IO.Put_Line (Integer'Image (R.D1 + R.D2) & Integer'Image (X / 1E9) & Integer'Image (Boolean'Pos (if B then True else False)));
end Main;
