[Python-checkins] cpython (2.7): fix hash member name (closes #22847)

benjamin.peterson python-checkins at python.org
Sun Feb 7 01:36:11 EST 2016


https://hg.python.org/cpython/rev/04424651f76c
changeset:   100175:04424651f76c
branch:      2.7
user:        Benjamin Peterson <benjamin at python.org>
date:        Sat Feb 06 22:36:06 2016 -0800
summary:
  fix hash member name (closes #22847)

files:
  Objects/typeobject.c |  2 +-
  1 files changed, 1 insertions(+), 1 deletions(-)


diff --git a/Objects/typeobject.c b/Objects/typeobject.c
--- a/Objects/typeobject.c
+++ b/Objects/typeobject.c
@@ -2565,7 +2565,7 @@
         method_cache[h].version = type->tp_version_tag;
         method_cache[h].value = res;  /* borrowed */
         Py_INCREF(name);
-        assert(((PyStringObject *)(name))->hash != -1);
+        assert(((PyStringObject *)(name))->ob_shash != -1);
 #if MCACHE_STATS
         if (method_cache[h].name != Py_None && method_cache[h].name != name)
             method_cache_collisions++;

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


More information about the Python-checkins mailing list