[EMAIL PROTECTED] writes:

> >>> t.timeTime()
> 953146937.0
> >>> int( t.timeTime() )
> 953146936                  <<<<< This is wrong
> >>> int( 953146937.0 )
> 953146937           
> 
> Any ideas on how this can be happening. Stepping through the DateTime module
> yields the sensible return value of 953146937.0 but somehow int() converts
> this incorrectly.

int() works fine (truncating everything behind "."):

>>> t.timeTime() == 953146937.0
0
>>> t.timeTime() -  953146937.0
-4.76837158203e-07                  
>>> int (round (t.timeTime()))
953146937                                                                       

jens


-- 
                                                       http://www.jquade.de/

And here they are: Nitwit! Blubber! Oddment! Tweak!
                                      -- Albus Dumbledore


_______________________________________________
Zope maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope-dev )

Reply via email to