diff options
author | Neil Schemenauer <nascheme@enme.ucalgary.ca> | 2002-11-24 01:07:42 (GMT) |
---|---|---|
committer | Neil Schemenauer <nascheme@enme.ucalgary.ca> | 2002-11-24 01:07:42 (GMT) |
commit | d46fbc322d0a057c3c4f0af801d28ea65074c4c7 (patch) | |
tree | fba660d8b2d32fffb0ec63d9ebfe5597c32ef8e0 /Objects | |
parent | 761b6095bd6a30fe92c9756d6dd31855d87c2b71 (diff) | |
download | cpython-d46fbc322d0a057c3c4f0af801d28ea65074c4c7.zip cpython-d46fbc322d0a057c3c4f0af801d28ea65074c4c7.tar.gz cpython-d46fbc322d0a057c3c4f0af801d28ea65074c4c7.tar.bz2 |
Remove special handling of str and unicode in PyNumber_InPlaceRemainder. They
both have a nb_remainer slot.
Diffstat (limited to 'Objects')
-rw-r--r-- | Objects/abstract.c | 11 |
1 files changed, 2 insertions, 9 deletions
diff --git a/Objects/abstract.c b/Objects/abstract.c index 2df934d..8845dce 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 * |