Alexander Belopolsky <belopol...@users.sourceforge.net> added the comment:
Mark, I am reassigning this to you for commit review. I am changing the title to reflect the visible part of the change. The datetime module gains direct access to system gettimeofday at the C level while time module grows time.gettimeofday() Python method. I am not sure I made the best choice defining struct timeval on systems without gettimeofday. Maybe it is better to do typedef struct timeval _PyTime_timeval; on systems with gettimeofday and equivalent explicit definition on systems without. The cast selection logic for time_t is a bit of a hack as well, but this is the best I could come up with without resorting to configure tests. Unless this breaks on a known platform, I would rather commit this as is and have a separate project to clean up cross-platform time handling later. This patch builds on refactoring started in issue9012. ---------- assignee: belopolsky -> mark.dickinson stage: patch review -> commit review title: Make gettimeofday available in datetime module -> Make gettimeofday available in time module type: -> feature request _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue9079> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com