This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author Oren Milman
Recipients Oren Milman
Date 2016-05-24.20:43:24
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
------------ the proposed changes ------------
In Objects/longobject.c in long_add and long_sub, the variables 'result' and 'r' (respectively), are used only once, and don't seem to make the code any clearer.

It seems the 'result' and 'r' variables were added in revision 40751. Back then, CONVERT_BINOP was used, and required calling Py_DECREF for a and b before returning.
Later on, in revision 43313, CONVERT_BINOP was removed, along with the calls to Py_DECREF it required, but the 'result' and 'r' variables were left untouched, and remained there to this day.

------------ diff ------------
The patches diff is attached.

------------ tests ------------
I built the patched CPython for x86, and played with it a little. Everything seemed to work as usual.

In addition, I ran 'python -m test' (on my 64-bit Windows 10) before and after applying the patch, and got quite the same output.
the outputs of both runs are attached.
Date User Action Args
2016-05-24 20:43:24Oren Milmansetrecipients: + Oren Milman
2016-05-24 20:43:24Oren Milmansetmessageid: <>
2016-05-24 20:43:24Oren Milmanlinkissue27111 messages
2016-05-24 20:43:24Oren Milmancreate