[Python-checkins] bpo-39237, datetime: Remove redundant call to round from delta_new (GH-17877)
Victor Stinner
webhook-mailer at python.org
Wed Jan 8 07:52:49 EST 2020
https://github.com/python/cpython/commit/998c54948a29cf5bd8bfa49f973f1ce5855004a0
commit: 998c54948a29cf5bd8bfa49f973f1ce5855004a0
branch: master
author: Alex Henrie <alexhenrie24 at gmail.com>
committer: Victor Stinner <vstinner at python.org>
date: 2020-01-08T13:52:44+01:00
summary:
bpo-39237, datetime: Remove redundant call to round from delta_new (GH-17877)
files:
M Modules/_datetimemodule.c
diff --git a/Modules/_datetimemodule.c b/Modules/_datetimemodule.c
index c1b24073436e6..0b98cca67d4c5 100644
--- a/Modules/_datetimemodule.c
+++ b/Modules/_datetimemodule.c
@@ -2489,7 +2489,6 @@ delta_new(PyTypeObject *type, PyObject *args, PyObject *kw)
int x_is_odd;
PyObject *temp;
- whole_us = round(leftover_us);
if (fabs(whole_us - leftover_us) == 0.5) {
/* We're exactly halfway between two integers. In order
* to do round-half-to-even, we must determine whether x
More information about the Python-checkins
mailing list