mirror of
https://github.com/python/cpython.git
synced 2025-09-27 02:39:58 +00:00
Remove some shadowed variables
This commit is contained in:
parent
76dc081dd9
commit
0c6e2f1640
3 changed files with 4 additions and 4 deletions
|
@ -415,7 +415,7 @@ binary_op1(PyObject *v, PyObject *w, const int op_slot)
|
||||||
binaryfunc slot;
|
binaryfunc slot;
|
||||||
slot = NB_BINOP(mv, op_slot);
|
slot = NB_BINOP(mv, op_slot);
|
||||||
if (slot) {
|
if (slot) {
|
||||||
PyObject *x = slot(v, w);
|
x = slot(v, w);
|
||||||
Py_DECREF(v);
|
Py_DECREF(v);
|
||||||
Py_DECREF(w);
|
Py_DECREF(w);
|
||||||
return x;
|
return x;
|
||||||
|
|
|
@ -846,7 +846,7 @@ set_update_internal(PySetObject *so, PyObject *other)
|
||||||
return set_merge(so, other);
|
return set_merge(so, other);
|
||||||
|
|
||||||
if (PyDict_Check(other)) {
|
if (PyDict_Check(other)) {
|
||||||
PyObject *key, *value;
|
PyObject *value;
|
||||||
int pos = 0;
|
int pos = 0;
|
||||||
while (PyDict_Next(other, &pos, &key, &value)) {
|
while (PyDict_Next(other, &pos, &key, &value)) {
|
||||||
if (set_add_key(so, key) == -1)
|
if (set_add_key(so, key) == -1)
|
||||||
|
|
|
@ -920,8 +920,8 @@ PyObject_ClearWeakRefs(PyObject *object)
|
||||||
PyObject *callback = PyTuple_GET_ITEM(tuple, i * 2 + 1);
|
PyObject *callback = PyTuple_GET_ITEM(tuple, i * 2 + 1);
|
||||||
|
|
||||||
if (callback != NULL) {
|
if (callback != NULL) {
|
||||||
PyObject *current = PyTuple_GET_ITEM(tuple, i * 2);
|
PyObject *item = PyTuple_GET_ITEM(tuple, i * 2);
|
||||||
handle_callback((PyWeakReference *)current, callback);
|
handle_callback((PyWeakReference *)item, callback);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Py_DECREF(tuple);
|
Py_DECREF(tuple);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue