Re: [AD] use double for al_current_time and al_rest?

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


On Thu, 2007-12-27 at 18:14 +0100, Andrei Ellman wrote:
> 
> Using a floating point value for timers is not a good idea because once 
> the exponent gets too large, the precision of the value to al_rest() for 
> decreases, and eventually, the current_time value will become so large 
> that the amount to rest() for will underflow. While underflow may not 
> happen for a long time, if someone wants to al_rest() for a 
> high-precision ammount of time, the actual time rested will be inconsistent.

Yes, but as I said, this is very unlikely to be an isse - for a timespan
of 90 days double would stay at nanosecond precision (whereas the
current version already would wrap around the milliseconds at 50 days).

-- 
Elias Pschernig <elias@xxxxxxxxxx>





Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/