a-ztexio.adb, [...]: Replace bad range checks with 'Valid tests.
2005-09-01 Robert Dewar <dewar@adacore.com> * a-ztexio.adb, a-textio.adb, a-witeio.adb: Replace bad range checks with 'Valid tests. From-SVN: r103858
This commit is contained in:
parent
2ede092bd7
commit
405e57adc0
|
@ -896,7 +896,7 @@ package body Ada.Text_IO is
|
|||
-- explicit test is that we don't want junk values around, even if
|
||||
-- checks are off in the caller.
|
||||
|
||||
if Spacing not in Positive_Count then
|
||||
if not Spacing'Valid then
|
||||
raise Constraint_Error;
|
||||
end if;
|
||||
|
||||
|
@ -1334,7 +1334,7 @@ package body Ada.Text_IO is
|
|||
-- explicit test is that we don't want junk values around, even if
|
||||
-- checks are off in the caller.
|
||||
|
||||
if To not in Positive_Count then
|
||||
if not To'Valid then
|
||||
raise Constraint_Error;
|
||||
end if;
|
||||
|
||||
|
@ -1461,7 +1461,7 @@ package body Ada.Text_IO is
|
|||
-- explicit test is that we don't want junk values around, even if
|
||||
-- checks are off in the caller.
|
||||
|
||||
if To not in Positive_Count then
|
||||
if not To'Valid then
|
||||
raise Constraint_Error;
|
||||
end if;
|
||||
|
||||
|
@ -1506,7 +1506,7 @@ package body Ada.Text_IO is
|
|||
-- explicit test is that we don't want junk values around, even if
|
||||
-- checks are off in the caller.
|
||||
|
||||
if To not in Count then
|
||||
if not To'Valid then
|
||||
raise Constraint_Error;
|
||||
end if;
|
||||
|
||||
|
@ -1539,7 +1539,7 @@ package body Ada.Text_IO is
|
|||
-- explicit test is that we don't want junk values around, even if
|
||||
-- checks are off in the caller.
|
||||
|
||||
if To not in Count then
|
||||
if not To'Valid then
|
||||
raise Constraint_Error;
|
||||
end if;
|
||||
|
||||
|
@ -1567,7 +1567,7 @@ package body Ada.Text_IO is
|
|||
-- explicit test is that we don't want junk values around, even if
|
||||
-- checks are off in the caller.
|
||||
|
||||
if Spacing not in Positive_Count then
|
||||
if not Spacing'Valid then
|
||||
raise Constraint_Error;
|
||||
end if;
|
||||
|
||||
|
|
|
@ -987,7 +987,7 @@ package body Ada.Wide_Text_IO is
|
|||
-- explicit test is that we don't want junk values around, even if
|
||||
-- checks are off in the caller.
|
||||
|
||||
if Spacing not in Positive_Count then
|
||||
if not Spacing'Valid then
|
||||
raise Constraint_Error;
|
||||
end if;
|
||||
|
||||
|
@ -1346,7 +1346,7 @@ package body Ada.Wide_Text_IO is
|
|||
-- explicit test is that we don't want junk values around, even if
|
||||
-- checks are off in the caller.
|
||||
|
||||
if To not in Positive_Count then
|
||||
if not To'Valid then
|
||||
raise Constraint_Error;
|
||||
end if;
|
||||
|
||||
|
@ -1434,7 +1434,7 @@ package body Ada.Wide_Text_IO is
|
|||
-- explicit test is that we don't want junk values around, even if
|
||||
-- checks are off in the caller.
|
||||
|
||||
if To not in Positive_Count then
|
||||
if not To'Valid then
|
||||
raise Constraint_Error;
|
||||
end if;
|
||||
|
||||
|
@ -1479,7 +1479,7 @@ package body Ada.Wide_Text_IO is
|
|||
-- explicit test is that we don't want junk values around, even if
|
||||
-- checks are off in the caller.
|
||||
|
||||
if To not in Count then
|
||||
if not To'Valid then
|
||||
raise Constraint_Error;
|
||||
end if;
|
||||
|
||||
|
@ -1512,7 +1512,7 @@ package body Ada.Wide_Text_IO is
|
|||
-- explicit test is that we don't want junk values around, even if
|
||||
-- checks are off in the caller.
|
||||
|
||||
if To not in Count then
|
||||
if not To'Valid then
|
||||
raise Constraint_Error;
|
||||
end if;
|
||||
|
||||
|
@ -1570,7 +1570,7 @@ package body Ada.Wide_Text_IO is
|
|||
-- explicit test is that we don't want junk values around, even if
|
||||
-- checks are off in the caller.
|
||||
|
||||
if Spacing not in Positive_Count then
|
||||
if not Spacing'Valid then
|
||||
raise Constraint_Error;
|
||||
end if;
|
||||
|
||||
|
|
|
@ -988,7 +988,7 @@ package body Ada.Wide_Wide_Text_IO is
|
|||
-- explicit test is that we don't want junk values around, even if
|
||||
-- checks are off in the caller.
|
||||
|
||||
if Spacing not in Positive_Count then
|
||||
if not Spacing'Valid then
|
||||
raise Constraint_Error;
|
||||
end if;
|
||||
|
||||
|
@ -1348,7 +1348,7 @@ package body Ada.Wide_Wide_Text_IO is
|
|||
-- explicit test is that we don't want junk values around, even if
|
||||
-- checks are off in the caller.
|
||||
|
||||
if To not in Positive_Count then
|
||||
if not To'Valid then
|
||||
raise Constraint_Error;
|
||||
end if;
|
||||
|
||||
|
@ -1436,7 +1436,7 @@ package body Ada.Wide_Wide_Text_IO is
|
|||
-- explicit test is that we don't want junk values around, even if
|
||||
-- checks are off in the caller.
|
||||
|
||||
if To not in Positive_Count then
|
||||
if not To'Valid then
|
||||
raise Constraint_Error;
|
||||
end if;
|
||||
|
||||
|
@ -1481,7 +1481,7 @@ package body Ada.Wide_Wide_Text_IO is
|
|||
-- explicit test is that we don't want junk values around, even if
|
||||
-- checks are off in the caller.
|
||||
|
||||
if To not in Count then
|
||||
if not To'Valid then
|
||||
raise Constraint_Error;
|
||||
end if;
|
||||
|
||||
|
@ -1514,7 +1514,7 @@ package body Ada.Wide_Wide_Text_IO is
|
|||
-- explicit test is that we don't want junk values around, even if
|
||||
-- checks are off in the caller.
|
||||
|
||||
if To not in Count then
|
||||
if not To'Valid then
|
||||
raise Constraint_Error;
|
||||
end if;
|
||||
|
||||
|
@ -1572,7 +1572,7 @@ package body Ada.Wide_Wide_Text_IO is
|
|||
-- explicit test is that we don't want junk values around, even if
|
||||
-- checks are off in the caller.
|
||||
|
||||
if Spacing not in Positive_Count then
|
||||
if not Spacing'Valid then
|
||||
raise Constraint_Error;
|
||||
end if;
|
||||
|
||||
|
|
Loading…
Reference in New Issue