[Python-3000] A better way to initialize PyTypeObject
Greg Ewing
greg.ewing at canterbury.ac.nz
Thu Nov 30 01:34:44 CET 2006
Ronald Oussoren wrote:
> It is already possibly to extend the
> type struct in Python 2.3 and later
From Python?
Python 2.3 (#1, Aug 5 2003, 15:52:30)
[GCC 3.1 20020420 (prerelease)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> class C(type):
... __slots__ = ['foo']
...
Traceback (most recent call last):
File "<stdin>", line 1, in ?
TypeError: nonempty __slots__ not supported for subtype of 'type'
That looks to me like the type object is not
a full member of the Python community just
yet.
--
Greg
More information about the Python-3000
mailing list