Простые типы / Числа / Integer

uses System.SysUtils;

var
  B1B2B3Byte;
begin
  //no range check by default
  {$RANGECHECKS OFF}
  B1 := 200;
  B2 := 100;
  B3 := B1 + B2;
  //B3 is 44 (300 - 256)
  WriteLn('b3 = 'B3);

  //with the checks the same code
  //raises ERangeError
  {$RANGECHECKS ON}
  try
    B3 := B1 + B2;
  except
    on E: ERangeError do
      WriteLn('range error detected');
  end;
end.