]> granicus.if.org Git - python/commitdiff
Minor beautification. Put updates and declarations in a more logical order.
authorRaymond Hettinger <python@rcn.com>
Sat, 21 Sep 2013 22:39:49 +0000 (15:39 -0700)
committerRaymond Hettinger <python@rcn.com>
Sat, 21 Sep 2013 22:39:49 +0000 (15:39 -0700)
Objects/setobject.c

index 017fcd88db3ad75d91eacae280bc176d8a1ce9f6..22d9cb35cbe5bf47915fa793770e6ea3c52bd0fe 100644 (file)
@@ -60,8 +60,8 @@ set_lookkey(PySetObject *so, PyObject *key, Py_hash_t hash)
     size_t perturb = hash;
     size_t mask = so->mask;
     size_t i = (size_t)hash; /* Unsigned for defined overflow behavior. */
-    int cmp;
     size_t j;
+    int cmp;
 
     entry = &table[i & mask];
     if (entry->key == NULL)
@@ -211,9 +211,9 @@ set_insert_clean(PySetObject *so, PyObject *key, Py_hash_t hash)
         i = i * 5 + 1 + perturb;
     }
   found_null:
-    so->fill++;
     entry->key = key;
     entry->hash = hash;
+    so->fill++;
     so->used++;
 }