From 3747a0f04c1dbe5abb47ce80abea39ed02c01aa2 Mon Sep 17 00:00:00 2001 From: Guido van Rossum Date: Mon, 12 Aug 2002 19:25:08 +0000 Subject: [PATCH] Fix MSVC warnings. --- Objects/typeobject.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Objects/typeobject.c b/Objects/typeobject.c index 766318e0caa..bb05e6b87d2 100644 --- a/Objects/typeobject.c +++ b/Objects/typeobject.c @@ -940,9 +940,9 @@ subtype_getweakref(PyObject *obj, void *context) } assert(obj->ob_type->tp_weaklistoffset > 0); assert(obj->ob_type->tp_weaklistoffset + sizeof(PyObject *) <= - obj->ob_type->tp_basicsize); + (size_t)(obj->ob_type->tp_basicsize)); weaklistptr = (PyObject **) - ((void *)obj + obj->ob_type->tp_weaklistoffset); + ((char *)obj + obj->ob_type->tp_weaklistoffset); if (*weaklistptr == NULL) result = Py_None; else