{: test that passing an array to a conformant array parameter
   with incorrect bounds causes a fatal error }

{$d+}
program d102( output );

type
   smallInt =  1..10;

var
   a : array[1..11] of integer;

procedure test1(aa : array[lo..hi : smallInt] of integer);
var
   z   : smallInt;
begin
   z := lo;
   aa[z] := 3;
   aa[hi] := 3;
   writeln( 'fails: conformant array bounds error is not detected' );
end; { test1 }

procedure test2(aa : array[lo..hi : integer] of integer);
begin
   test1(aa);  { !!! bounds exceeded }
end;

begin {d102}

   test2(a);

end. { d102 }

