[Python-checkins] cpython: rearrange to make gcc happy
benjamin.peterson
python-checkins at python.org
Thu Sep 8 12:50:49 EDT 2016
https://hg.python.org/cpython/rev/22c0c4d36782
changeset: 103316:22c0c4d36782
user: Benjamin Peterson <benjamin at python.org>
date: Thu Sep 08 09:50:08 2016 -0700
summary:
rearrange to make gcc happy
files:
Objects/dictobject.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/Objects/dictobject.c b/Objects/dictobject.c
--- a/Objects/dictobject.c
+++ b/Objects/dictobject.c
@@ -2012,6 +2012,7 @@
{
PyObject *v;
Py_ssize_t i, j;
+ PyDictKeyEntry *ep;
Py_ssize_t size, n, offset;
PyObject **value_ptr;
@@ -2027,13 +2028,14 @@
Py_DECREF(v);
goto again;
}
+ ep = DK_ENTRIES(mp->ma_keys);
size = mp->ma_keys->dk_nentries;
if (mp->ma_values) {
value_ptr = mp->ma_values;
offset = sizeof(PyObject *);
}
else {
- value_ptr = &(DK_ENTRIES(mp->ma_keys)[0].me_value);
+ value_ptr = &ep[0].me_value;
offset = sizeof(PyDictKeyEntry);
}
for (i = 0, j = 0; i < size; i++) {
--
Repository URL: https://hg.python.org/cpython
More information about the Python-checkins
mailing list