From 90dea4ce43a0ebfe9961e854b605d167e0f57863 Mon Sep 17 00:00:00 2001 From: Raymond Hettinger Date: Sat, 13 Jul 2013 22:30:25 -0700 Subject: Tweak the deque struct by moving the least used fields (maxlen and weakref) to the end. --- Modules/_collectionsmodule.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Modules/_collectionsmodule.c b/Modules/_collectionsmodule.c index 21cc21dac9..5d5fc912a1 100644 --- a/Modules/_collectionsmodule.c +++ b/Modules/_collectionsmodule.c @@ -119,8 +119,8 @@ typedef struct { block *rightblock; Py_ssize_t leftindex; /* in range(BLOCKLEN) */ Py_ssize_t rightindex; /* in range(BLOCKLEN) */ + long state; /* incremented whenever the indices move */ Py_ssize_t maxlen; - long state; /* incremented whenever the indices move */ PyObject *weakreflist; /* List of weak references */ } dequeobject; -- cgit v1.2.1