diff options
author | Georg Brandl <georg@python.org> | 2007-04-11 19:24:50 (GMT) |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2007-04-11 19:24:50 (GMT) |
commit | 57b39e0916d741d9851ac875d8f443bfc6005def (patch) | |
tree | 582159ea9ac83512264eb4ecb442f4bf19e7712f /Lib/idlelib | |
parent | b5ddcfd2a203336f3ba7bb1111cda462333c9e1f (diff) | |
download | cpython-57b39e0916d741d9851ac875d8f443bfc6005def.zip cpython-57b39e0916d741d9851ac875d8f443bfc6005def.tar.gz cpython-57b39e0916d741d9851ac875d8f443bfc6005def.tar.bz2 |
Bug #1697782: remove all remaining code that uses types.InstanceType.
Diffstat (limited to 'Lib/idlelib')
-rw-r--r-- | Lib/idlelib/ObjectBrowser.py | 10 | ||||
-rw-r--r-- | Lib/idlelib/rpc.py | 2 |
2 files changed, 0 insertions, 12 deletions
diff --git a/Lib/idlelib/ObjectBrowser.py b/Lib/idlelib/ObjectBrowser.py index b4f64b6..3ef5bb9 100644 --- a/Lib/idlelib/ObjectBrowser.py +++ b/Lib/idlelib/ObjectBrowser.py @@ -57,15 +57,6 @@ class ObjectTreeItem(TreeItem): sublist.append(item) return sublist -class InstanceTreeItem(ObjectTreeItem): - def IsExpandable(self): - return True - def GetSubList(self): - sublist = ObjectTreeItem.GetSubList(self) - sublist.insert(0, - make_objecttreeitem("__class__ =", self.object.__class__)) - return sublist - class ClassTreeItem(ObjectTreeItem): def IsExpandable(self): return True @@ -120,7 +111,6 @@ dispatch = { TupleType: SequenceTreeItem, ListType: SequenceTreeItem, DictType: DictTreeItem, - InstanceType: InstanceTreeItem, ClassType: ClassTreeItem, } diff --git a/Lib/idlelib/rpc.py b/Lib/idlelib/rpc.py index 169bceb..57a975a 100644 --- a/Lib/idlelib/rpc.py +++ b/Lib/idlelib/rpc.py @@ -574,8 +574,6 @@ def _getmethods(obj, methods): attr = getattr(obj, name) if callable(attr): methods[name] = 1 - if type(obj) == types.InstanceType: - _getmethods(obj.__class__, methods) if type(obj) == types.ClassType: for super in obj.__bases__: _getmethods(super, methods) |