[New-bugs-announce] [issue12203] isinstance not functioning as documented

Joesph report at bugs.python.org
Sun May 29 02:41:34 CEST 2011


New submission from Joesph <someone3x7 at gmail.com>:

#Example:
class a(object):
    pass

b = a()

print([isinstance(a,object), isinstance(b,object)])

'''
outputs: [True, True]
expected: [False, True]

As class a is not instantiated it should return false. As-is isinstance is just a synonym for issubclass.
'''

----------
components: Interpreter Core
messages: 137160
nosy: someone3x7
priority: normal
severity: normal
status: open
title: isinstance not functioning as documented
versions: Python 3.2

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue12203>
_______________________________________


More information about the New-bugs-announce mailing list