From: Neil Schemenauer Date: Sun, 24 Nov 2002 01:07:42 +0000 (+0000) Subject: Remove special handling of str and unicode in PyNumber_InPlaceRemainder. They X-Git-Tag: v2.3c1~3268 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=d46fbc322d0a057c3c4f0af801d28ea65074c4c7;p=thirdparty%2FPython%2Fcpython.git Remove special handling of str and unicode in PyNumber_InPlaceRemainder. They both have a nb_remainer slot. --- diff --git a/Objects/abstract.c b/Objects/abstract.c index 2df934db8afd..8845dce71c95 100644 --- a/Objects/abstract.c +++ b/Objects/abstract.c @@ -764,15 +764,8 @@ PyNumber_InPlaceMultiply(PyObject *v, PyObject *w) PyObject * PyNumber_InPlaceRemainder(PyObject *v, PyObject *w) { - if (PyString_Check(v)) - return PyString_Format(v, w); -#ifdef Py_USING_UNICODE - else if (PyUnicode_Check(v)) - return PyUnicode_Format(v, w); -#endif - else - return binary_iop(v, w, NB_SLOT(nb_inplace_remainder), - NB_SLOT(nb_remainder), "%="); + return binary_iop(v, w, NB_SLOT(nb_inplace_remainder), + NB_SLOT(nb_remainder), "%="); } PyObject *