[Python-checkins] cpython: Put the defines in the logical section and fix indentation.

raymond.hettinger python-checkins at python.org
Sun Sep 8 09:26:04 CEST 2013


http://hg.python.org/cpython/rev/b03f98c1052f
changeset:   85614:b03f98c1052f
user:        Raymond Hettinger <python at rcn.com>
date:        Sun Sep 08 00:25:57 2013 -0700
summary:
  Put the defines in the logical section and fix indentation.

files:
  Objects/setobject.c |  16 ++++++++--------
  1 files changed, 8 insertions(+), 8 deletions(-)


diff --git a/Objects/setobject.c b/Objects/setobject.c
--- a/Objects/setobject.c
+++ b/Objects/setobject.c
@@ -31,12 +31,6 @@
 #include "structmember.h"
 #include "stringlib/eq.h"
 
-/* This must be >= 1 */
-#define PERTURB_SHIFT 5
-
-/* This should be >= PySet_MINSIZE - 1 */
-#define LINEAR_PROBES 9
-
 /* Object used as dummy key to fill deleted entries */
 static PyObject _dummy_struct;
 
@@ -49,6 +43,12 @@
 /* ======================================================================== */
 /* ======= Begin logic for probing the hash table ========================= */
 
+/* This should be >= PySet_MINSIZE - 1 */
+#define LINEAR_PROBES 9
+
+/* This must be >= 1 */
+#define PERTURB_SHIFT 5
+
 static setentry *
 set_lookkey(PySetObject *so, PyObject *key, Py_hash_t hash)
 {
@@ -151,8 +151,8 @@
     while (1) {
         if (entry->key == key
             || (entry->hash == hash
-            && entry->key != dummy
-            && unicode_eq(entry->key, key)))
+                && entry->key != dummy
+                && unicode_eq(entry->key, key)))
             return entry;
         if (entry->key == dummy && freeslot == NULL)
             freeslot = entry;

-- 
Repository URL: http://hg.python.org/cpython


More information about the Python-checkins mailing list