diff options
author | Neal Norwitz <nnorwitz@gmail.com> | 2006-03-24 08:14:36 (GMT) |
---|---|---|
committer | Neal Norwitz <nnorwitz@gmail.com> | 2006-03-24 08:14:36 (GMT) |
commit | bcc0db82dc9cb474d56a4cc63748583232d9524f (patch) | |
tree | 0107d20b29b61fc7dfd9626ee7257242f8cf6302 /Objects/longobject.c | |
parent | ed483ba63b9c03845386976bccff5d95df5b570a (diff) | |
download | cpython-bcc0db82dc9cb474d56a4cc63748583232d9524f.zip cpython-bcc0db82dc9cb474d56a4cc63748583232d9524f.tar.gz cpython-bcc0db82dc9cb474d56a4cc63748583232d9524f.tar.bz2 |
Get rid of remnants of integer division
Diffstat (limited to 'Objects/longobject.c')
-rw-r--r-- | Objects/longobject.c | 18 |
1 files changed, 0 insertions, 18 deletions
diff --git a/Objects/longobject.c b/Objects/longobject.c index e47c292..7c5ebc4 100644 --- a/Objects/longobject.c +++ b/Objects/longobject.c @@ -2355,22 +2355,6 @@ long_div(PyObject *v, PyObject *w) } static PyObject * -long_classic_div(PyObject *v, PyObject *w) -{ - PyLongObject *a, *b, *div; - - CONVERT_BINOP(v, w, &a, &b); - if (Py_DivisionWarningFlag && - PyErr_Warn(PyExc_DeprecationWarning, "classic long division") < 0) - div = NULL; - else if (l_divmod(a, b, &div, NULL) < 0) - div = NULL; - Py_DECREF(a); - Py_DECREF(b); - return (PyObject *)div; -} - -static PyObject * long_true_divide(PyObject *v, PyObject *w) { PyLongObject *a, *b; @@ -3130,7 +3114,6 @@ static PyNumberMethods long_as_number = { (binaryfunc) long_add, /*nb_add*/ (binaryfunc) long_sub, /*nb_subtract*/ (binaryfunc) long_mul, /*nb_multiply*/ - (binaryfunc) long_classic_div, /*nb_divide*/ (binaryfunc) long_mod, /*nb_remainder*/ (binaryfunc) long_divmod, /*nb_divmod*/ (ternaryfunc) long_pow, /*nb_power*/ @@ -3153,7 +3136,6 @@ static PyNumberMethods long_as_number = { 0, /* nb_inplace_add */ 0, /* nb_inplace_subtract */ 0, /* nb_inplace_multiply */ - 0, /* nb_inplace_divide */ 0, /* nb_inplace_remainder */ 0, /* nb_inplace_power */ 0, /* nb_inplace_lshift */ |