Re: Ada.Real_Time Vs. Ada.Calendar
- From: "Jeffrey R. Carter" <spam.not.jrcarter@xxxxxxxxxxxxxxxx>
- Date: Wed, 22 Nov 2006 17:02:11 GMT
markp wrote:
I need to compare data types that are stored in Ada.Real_Time.Time and
Ada.Calendar.Time. I know I can get a seconds count from each package.
However, is it the same time base? Is it dependant on the hardware it
is run on?
In general, you can't count on them having any meaningful relationship. Real_Time may be a count of ticks since the program started, for example, while Calendar must be a date and time CE.
How they are implemented is not specified, which is not surprising.
For a specific compiler and platform, you may be able to make use of compiler-dependent information to relate the two. GNAT, for example, defines both Time types as "new Duration". That doesn't guarantee that the stored values have the same meaning, though.
--
Jeff Carter
"We burst our pimples at you."
Monty Python & the Holy Grail
16
.
- Follow-Ups:
- Re: Ada.Real_Time Vs. Ada.Calendar
- From: Simon Wright
- Re: Ada.Real_Time Vs. Ada.Calendar
- References:
- Ada.Real_Time Vs. Ada.Calendar
- From: markp
- Ada.Real_Time Vs. Ada.Calendar
- Prev by Date: Re: Profiler?
- Next by Date: Re: Profiler?
- Previous by thread: Ada.Real_Time Vs. Ada.Calendar
- Next by thread: Re: Ada.Real_Time Vs. Ada.Calendar
- Index(es):