wyz23x2 <wyz2...@163.com> added the comment:

OK, so:
>>> (1).__slots__
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
AttributeError: 'int' object has no attribute '__slots__'
>>> 4.5.__slots__
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
AttributeError: 'float' object has no attribute '__slots__'
>>> complex(5, 2).__slots__
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
AttributeError: 'complex' object has no attribute '__slots__'
>>> 'Hello'.__slots__
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
AttributeError: 'str' object has no attribute '__slots__'
>>> b'50'.__slots__
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
AttributeError: 'bytes' object has no attribute '__slots__'
>>> [2.72, 3.14].__slots__
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
AttributeError: 'list' object has no attribute '__slots__'
>>> 

Many many more.
So these *all* need __slots__???
That a major change into Python 5000.

----------
nosy: +wyz23x2

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue44318>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to