[Python-Dev] Subsecond time stamps

Brian Quinlan brian@sweetapp.com
Mon, 09 Sep 2002 16:55:15 -0700


MvL wrote:

> That's not true. Support you have two fields, tv_sec and tv_nsec. Then
> the resulting float expression is
> 
>    tv_sec + 1e-9 * tv_nsec;
> 
> This expression works on all systems that support floating point
> numbers - be it IEEE or not.

Don't you have to truncate tv_sec for that to work? i.e.

	Truncate(tv_sec, 9) + 1e-9 * tv_nsec

Cheers,
Brian