From: Yury Selivanov Date: Sat, 6 Feb 2016 17:21:33 +0000 (-0500) Subject: Issue #26288: Fix comment X-Git-Tag: v3.6.0a1~646 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=a0fcaca4e1c29078f578fb96971398c70cf38900;p=python Issue #26288: Fix comment --- diff --git a/Objects/longobject.c b/Objects/longobject.c index c1edeacf62..f3afb109f7 100644 --- a/Objects/longobject.c +++ b/Objects/longobject.c @@ -2770,9 +2770,9 @@ PyLong_AsDouble(PyObject *v) return -1.0; } if (Py_ABS(Py_SIZE(v)) <= 1) { - /* Fast path; single digit will always fit decimal. - This improves performance of FP/long operations by at - least 20%. This is even visible on macro-benchmarks. + /* Fast path; single digit long (31 bits) will cast safely + to double. This improves performance of FP/long operations + by 20%. */ return (double)MEDIUM_VALUE((PyLongObject *)v); }