summaryrefslogtreecommitdiff
path: root/gcc/ada/a-catizo.ads
diff options
context:
space:
mode:
authorHristian Kirtchev <kirtchev@adacore.com>2007-04-06 11:15:21 +0200
committerArnaud Charlet <charlet@gcc.gnu.org>2007-04-06 11:15:21 +0200
commit42907632860e44cc8c8b49a0b74444f62791fb9c (patch)
tree7a061f08c1577dcad5f77bb59e183a711e8af6e1 /gcc/ada/a-catizo.ads
parent3d3bf932b985baee7ac3973208c0d775dcb93b5d (diff)
downloadgcc-42907632860e44cc8c8b49a0b74444f62791fb9c.tar.gz
a-calend-vms.ads, [...]: New version of Ada.Calendar which supports the new upper bound of Ada time...
2007-04-06 Hristian Kirtchev <kirtchev@adacore.com> Vincent Celier <celier@adacore.com> * a-calend-vms.ads, a-calend.ads, a-calend.adb, a-calend-vms.adb: New version of Ada.Calendar which supports the new upper bound of Ada time (2399-12-31 86_399.999999999). The following modifications have been made to the package: - New representation of time as count of nanoseconds since the start of Ada time (1901-1-1 0.0). - Target independent Split and Time_Of routines which service both Ada 95 and Ada 2005 code. - Target independent interface to the Ada 2005 children of Calendar. - Integrated leap seconds into Ada 95 and Ada 2005 mode. - Handling of non-leap centenial years. - Updated clock function. - Updated arithmetic and comparison operators. * a-caldel.adb (To_Duration): Add call to target independent routine in Ada.Calendar to handle the conversion of time to duration. * sysdep.c (__gnat_localtime_tzoff): Test timezone before setting off (UTC Offset). If timezone is obviously incorrect (outside of -14 hours .. 14 hours), set off to 0. (__gnat_localtime_tzoff for Lynx and VxWorks): Even though these targets do not have a natural time zone, GMT is used as a default. (__gnat_get_task_options): New. * a-direct.adb (Modification_Time): Add with and use clauses for Ada.Calendar and Ada. Calendar.Formatting. Remove with clause for Ada.Unchecked_Conversion since it is no longer needed. (Duration_To_Time): Removed. (OS_Time_To_Long_Integer): Removed. (Modification_Time): Rewritten to use Ada.Calendar and Ada.Calendar. Formatting Time_Of routines which automatically handle time zones, buffer periods and leap seconds. * a-calari.ads, a-calari.adb ("+", "-", Difference): Add calls to target independent routines in Ada.Calendar. * a-calfor.ads, a-calfor.adb: Code cleanup and addition of validity checks in various routines. (Day_Of_Week, Split, Time_Of): Add call to target independent routine in Ada.Calendar. * a-catizo.ads, a-catizo.adb (UTC_Time_Offset): Add call to target independent routine in Ada.Calendar. From-SVN: r123543
Diffstat (limited to 'gcc/ada/a-catizo.ads')
-rw-r--r--gcc/ada/a-catizo.ads9
1 files changed, 8 insertions, 1 deletions
diff --git a/gcc/ada/a-catizo.ads b/gcc/ada/a-catizo.ads
index 83907c48e08..decdf52b117 100644
--- a/gcc/ada/a-catizo.ads
+++ b/gcc/ada/a-catizo.ads
@@ -6,7 +6,7 @@
-- --
-- S p e c --
-- --
--- Copyright (C) 2005 - 2006, Free Software Foundation, Inc. --
+-- Copyright (C) 2005-2006, Free Software Foundation, Inc. --
-- --
-- This specification is derived from the Ada Reference Manual for use with --
-- GNAT. The copyright notice above, and the license provisions that follow --
@@ -35,6 +35,9 @@
-- --
------------------------------------------------------------------------------
+-- This package provides routines to determine the offset of dates to GMT.
+-- It is defined in the Ada 2005 RM (9.6.1).
+
package Ada.Calendar.Time_Zones is
-- Time zone manipulation
@@ -44,5 +47,9 @@ package Ada.Calendar.Time_Zones is
Unknown_Zone_Error : exception;
function UTC_Time_Offset (Date : Time := Clock) return Time_Offset;
+ -- Returns, as a number of minutes, the difference between the
+ -- implementation-defined time zone of Calendar, and UTC time, at the time
+ -- Date. If the time zone of the Calendar implementation is unknown, then
+ -- Unknown_Zone_Error is raised.
end Ada.Calendar.Time_Zones;