(root)/
gcc-13.2.0/
gcc/
testsuite/
gnat.dg/
range_check7.adb
--  { dg-do compile }
--  { dg-options "-gnatVa" }

procedure Range_Check7 is

  type Short is range -32768 .. 32767;

  type Int is range -2 ** 31 .. 2 ** 31 - 1;

  subtype Nat is Int range 0 .. Int'Last;

  type Ptr is access all Short;

  procedure Proc (P : Ptr) is
    N : constant Nat := Nat (P.all);
  begin
    null;
  end;

begin
  null;
end;