Nick Coghlan <ncogh...@gmail.com> added the comment:

Deriving __int__ from __float__ wouldn't be the right answer, as that can 
easily lead to unwanted OverflowError exceptions and other issues.

However, Jeroen's suggested order of checking __index__ then __float__ then 
__int__ in _PyTime_FromObject makes sense to me, as that addresses Victor's 
desire to use the most precise conversion available.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue35707>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to