diff --git a/Objects/typeobject.c b/Objects/typeobject.c index 16b1a3035d5..43633f04475 100644 --- a/Objects/typeobject.c +++ b/Objects/typeobject.c @@ -2712,8 +2712,7 @@ type_new_visit_slots(type_new_ctx *ctx) if (!ctx->may_add_weak || ctx->add_weak != 0) { PyErr_SetString(PyExc_TypeError, "__weakref__ slot disallowed: " - "either we already got one, " - "or __itemsize__ != 0"); + "we already got one"); return -1; } ctx->add_weak++;