summaryrefslogtreecommitdiffstats
path: root/Python/bltinmodule.c
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>1997-12-10 05:51:47 (GMT)
committerGuido van Rossum <guido@python.org>1997-12-10 05:51:47 (GMT)
commitd6af46d4aef833099a405c18cd3b391298bddcff (patch)
tree1a1ac347d171cfcc0aad6c7cf051a47cabee833f /Python/bltinmodule.c
parentd5559576c93f33dc76dcd1dce84e79ccc2e261a8 (diff)
downloadcpython-d6af46d4aef833099a405c18cd3b391298bddcff.zip
cpython-d6af46d4aef833099a405c18cd3b391298bddcff.tar.gz
cpython-d6af46d4aef833099a405c18cd3b391298bddcff.tar.bz2
Need a cast when comparing type object in isinstance()
Diffstat (limited to 'Python/bltinmodule.c')
-rw-r--r--Python/bltinmodule.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Python/bltinmodule.c b/Python/bltinmodule.c
index 4019559..3460f1a 100644
--- a/Python/bltinmodule.c
+++ b/Python/bltinmodule.c
@@ -1628,7 +1628,7 @@ builtin_isinstance(self, args)
if (!PyArg_ParseTuple(args, "OO", &inst, &cls))
return NULL;
if (PyType_Check(cls)) {
- retval = (inst->ob_type == cls);
+ retval = ((PyObject *)(inst->ob_type) == cls);
}
else {
if (!PyClass_Check(cls)) {