From: "Jeffrey R. Carter" <spam.jrcarter.not@spam.acm.org>
Subject: Re: Dates and Times in GNAT on Linux
Date: Sun, 13 Sep 2009 12:35:37 -0700
Date: 2009-09-13T12:35:37-07:00 [thread overview]
Message-ID: <h8jh33$ik$1@news.tornevall.net> (raw)
In-Reply-To: <95e64$4aad119b$4a336034$30511@API-DIGITAL.COM>
Marc A. Criley wrote:
>
> I can then get the start of the Unix/UTC epoch via:
> UTC_Epoch_Start := Calendar.Time_Of(1970, 1, 1)
> + Duration(Calendar.Time_Zones.UTC_Offset * 60);
> -- For where I live, right now the UTC_Offset is -300 minutes,
> -- i.e. -5 hours.
This is your problem. The offset on 1970 Jan 01 00:00:00.00 was -6 hrs.
Of course, any attempt to relate an Ada.Real_Time.Time to an Ada.Calendar.Time
is completely compiler dependent, is unlikely to work with any other compiler,
and could stop working with a different version of the same compiler.
--
Jeff Carter
"C++: The power, elegance and simplicity of a hand grenade."
Ole-Hjalmar Kristensen
90
next prev parent reply other threads:[~2009-09-13 19:35 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-09-13 15:36 Dates and Times in GNAT on Linux Marc A. Criley
2009-09-13 16:17 ` Dmitry A. Kazakov
2009-09-13 19:35 ` Jeffrey R. Carter [this message]
2009-09-13 20:41 ` Marc A. Criley
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox