Make classes with __slots__ into new-style objects.
Move two class variable definitions into __init__(), because class variables defined in __slots__ are immutable. This should still be a net memory savings, because the a 8-entry dict and a 10-entry dict both have the same allocated size.
Showing
Please register or sign in to comment