def totime(somedate):
 if (not isinstance(somedate, time)):
  return time(somedate.hour, somedate.minute, somedate.second)
 assert isinstance(somedate, time), repr(somedate)
 return somedate

def totime ( somedate ) : if ( not isinstance ( somedate , time ) ) : return time ( somedate . hour , somedate . minute , somedate . second ) assert isinstance ( somedate , time ) , repr ( somedate ) return somedate
return a time from a time .