OSDN Git Service

* config/vax/vax.h (target_flags, MASK_UNIX_ASM, MASK_VAXC_ALIGNMENT)
[pf3gnuchains/gcc-fork.git] / gcc / ada / s-osprim.ads
index 381dd5e..76cebb5 100644 (file)
@@ -6,7 +6,7 @@
 --                                                                          --
 --                                  S p e c                                 --
 --                                                                          --
---          Copyright (C) 1998-2001 Free Software Foundation, Inc.          --
+--          Copyright (C) 1998-2003 Free Software Foundation, Inc.          --
 --                                                                          --
 -- GNARL is free software; you can  redistribute it  and/or modify it under --
 -- terms of the  GNU General Public License as published  by the Free Soft- --
@@ -27,7 +27,7 @@
 -- covered by the  GNU Public License.                                      --
 --                                                                          --
 -- GNARL was developed by the GNARL team at Florida State University.       --
--- Extensive contributions were provided by Ada Core Technologies Inc.      --
+-- Extensive contributions were provided by Ada Core Technologies, Inc.     --
 --                                                                          --
 ------------------------------------------------------------------------------
 
 
 package System.OS_Primitives is
 
-   Max_Sensible_Delay : constant Duration := 183 * 24 * 60 * 60.0;
+   Max_Sensible_Delay : constant Duration :=
+                          Duration'Min (183 * 24 * 60 * 60.0,
+                                        Duration'Last);
    --  Max of half a year delay, needed to prevent exceptions for large
    --  delay values. It seems unlikely that any test will notice this
    --  restriction, except in the case of applications setting the clock at
    --  at run time (see s-tastim.adb). Also note that a larger value might
    --  cause problems (e.g overflow, or more likely OS limitation in the
-   --  primitives used).
+   --  primitives used). In the case where half a year is too long (which
+   --  occurs in high integrity mode with 32-bit words, and possibly on
+   --  some specific ports of GNAT), Duration'Last is used instead.
 
    function Clock return Duration;
    pragma Inline (Clock);