Skip to content

Commit 2a65a47

Browse files
make is_new_style work on oldstyle class objects
1 parent 3a808fa commit 2a65a47

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

bpython/inspection.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ def is_new_style(obj):
104104
else:
105105
def is_new_style(obj):
106106
"""Returns True if obj is a new-style class or object"""
107-
return type(obj) != types.InstanceType
107+
return type(obj) not in [types.InstanceType, types.ClassType]
108108

109109

110110
class _Repr(object):

0 commit comments

Comments
 (0)