Commit f6622c8a authored by Benjamin Peterson's avatar Benjamin Peterson

fix build without Py_DEBUG and DNDEBUG (closes #14509)

parent 7fddb4b2
...@@ -896,7 +896,9 @@ bytes_hash(PyBytesObject *a) ...@@ -896,7 +896,9 @@ bytes_hash(PyBytesObject *a)
register unsigned char *p; register unsigned char *p;
register long x; register long x;
#ifdef Py_DEBUG
assert(_Py_HashSecret_Initialized); assert(_Py_HashSecret_Initialized);
#endif
if (a->ob_shash != -1) if (a->ob_shash != -1)
return a->ob_shash; return a->ob_shash;
len = Py_SIZE(a); len = Py_SIZE(a);
......
...@@ -7341,7 +7341,9 @@ unicode_hash(PyUnicodeObject *self) ...@@ -7341,7 +7341,9 @@ unicode_hash(PyUnicodeObject *self)
Py_UNICODE *p; Py_UNICODE *p;
long x; long x;
#ifdef Py_DEBUG
assert(_Py_HashSecret_Initialized); assert(_Py_HashSecret_Initialized);
#endif
if (self->hash != -1) if (self->hash != -1)
return self->hash; return self->hash;
len = Py_SIZE(self); len = Py_SIZE(self);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment