S
simon place
Removing __slots__
~~~~~~~~~~~~~~~~~~~
To do this nicely requires the renaming of __dict__ to, say,
__attribs__ , ( since dict is unnecessarily unspecific, this seem like a
small improvement in itself. ) then using the setting of __attribs__ to
a non-mutable type (ie tuple of attribute names) to indicate the
behaviour of __slots__, rendering it unnecessary, this I think is a good
simplification.
~~~~~~~~~~~~~~~~~~~
To do this nicely requires the renaming of __dict__ to, say,
__attribs__ , ( since dict is unnecessarily unspecific, this seem like a
small improvement in itself. ) then using the setting of __attribs__ to
a non-mutable type (ie tuple of attribute names) to indicate the
behaviour of __slots__, rendering it unnecessary, this I think is a good
simplification.