{: test that real division by zero causes a fatal error }

{$d+}
program d082( output );

var
   k : real;

function side : real;
begin
   side := k;
   k := k+1;
end;
begin {d082}

   k := 1;
   writeln( '11 / 1 is ', 11 / side:1:1);
   if k <> 2 then
      writeln( 'div operator for debug has side effects' );

   k := 0;
   writeln( '11 / 0 is ', 11 / 0.0:1 );
   writeln( 'fails: real division by zero error is not detected' );
   writeln( '11 / 0 is ', 11 / k:1 );
   writeln( 'fails: real division by zero error is not detected' );
end. { d082 }

