mirror of
https://github.com/python/cpython.git
synced 2025-10-10 00:43:41 +00:00
SF patch 1495675: Remove types.InstanceType and new.instance
(Collin Winter)
This commit is contained in:
parent
2018831b2b
commit
65810fee5e
11 changed files with 50 additions and 146 deletions
|
@ -56,9 +56,7 @@ class _C:
|
|||
def _m(self): pass
|
||||
ClassType = type(_C)
|
||||
UnboundMethodType = type(_C._m) # Same as MethodType
|
||||
_x = _C()
|
||||
InstanceType = type(_x)
|
||||
MethodType = type(_x._m)
|
||||
MethodType = type(_C()._m)
|
||||
|
||||
BuiltinFunctionType = type(len)
|
||||
BuiltinMethodType = type([].append) # Same as BuiltinFunctionType
|
||||
|
@ -86,4 +84,4 @@ EllipsisType = type(Ellipsis)
|
|||
DictProxyType = type(TypeType.__dict__)
|
||||
NotImplementedType = type(NotImplemented)
|
||||
|
||||
del sys, _f, _g, _C, _x # Not for export
|
||||
del sys, _f, _g, _C # Not for export
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue