Issue #16847: Fixed improper use of _PyUnicode_CheckConsistency() in
non-pydebug builds. Several extension modules now compile cleanly when
assert()s are enabled in standard builds (-DDEBUG flag).
diff --git a/Modules/md5module.c b/Modules/md5module.c
index e2681a8..12e187c 100644
--- a/Modules/md5module.c
+++ b/Modules/md5module.c
@@ -399,7 +399,9 @@
c = (digest[i] & 0xf);
hex_digest[j++] = Py_hexdigits[c];
}
+#ifdef Py_DEBUG
assert(_PyUnicode_CheckConsistency(retval, 1));
+#endif
return retval;
}