diff options
author | Neal Norwitz <nnorwitz@gmail.com> | 2006-03-16 06:02:10 (GMT) |
---|---|---|
committer | Neal Norwitz <nnorwitz@gmail.com> | 2006-03-16 06:02:10 (GMT) |
commit | c6d210ca7673c6ce0cb4b77ada22087f58372efc (patch) | |
tree | 905c39266f91fbeebbeb69a5848f9eb5808bc32c /Python | |
parent | e4993c7ac72842d18fb5689d7c77be2246b65708 (diff) | |
download | cpython-c6d210ca7673c6ce0cb4b77ada22087f58372efc.zip cpython-c6d210ca7673c6ce0cb4b77ada22087f58372efc.tar.gz cpython-c6d210ca7673c6ce0cb4b77ada22087f58372efc.tar.bz2 |
Get rid of last vestiges of BINARY_DIVIDE.
Diffstat (limited to 'Python')
-rw-r--r-- | Python/ceval.c | 13 | ||||
-rw-r--r-- | Python/compile.c | 6 |
2 files changed, 0 insertions, 19 deletions
diff --git a/Python/ceval.c b/Python/ceval.c index c854fcf..1a35610 100644 --- a/Python/ceval.c +++ b/Python/ceval.c @@ -1073,19 +1073,6 @@ PyEval_EvalFrameEx(PyFrameObject *f, int throw) if (x != NULL) continue; break; - case BINARY_DIVIDE: - if (!_Py_QnewFlag) { - w = POP(); - v = TOP(); - x = PyNumber_Divide(v, w); - Py_DECREF(v); - Py_DECREF(w); - SET_TOP(x); - if (x != NULL) continue; - break; - } - /* -Qnew is in effect: fall through to - BINARY_TRUE_DIVIDE */ case BINARY_TRUE_DIVIDE: w = POP(); v = TOP(); diff --git a/Python/compile.c b/Python/compile.c index cfc6ef1..9ce2bf7 100644 --- a/Python/compile.c +++ b/Python/compile.c @@ -479,11 +479,6 @@ fold_binops_on_constants(unsigned char *codestr, PyObject *consts) case BINARY_MULTIPLY: newconst = PyNumber_Multiply(v, w); break; - case BINARY_DIVIDE: - /* Cannot fold this operation statically since - the result can depend on the run-time presence - of the -Qnew flag */ - return 0; case BINARY_TRUE_DIVIDE: newconst = PyNumber_TrueDivide(v, w); break; @@ -1302,7 +1297,6 @@ opcode_stack_effect(int opcode, int oparg) case BINARY_POWER: case BINARY_MULTIPLY: - case BINARY_DIVIDE: case BINARY_MODULO: case BINARY_ADD: case BINARY_SUBTRACT: |