On Nov 4, 2:57 am, Glenn Linderman <[EMAIL PROTECTED]> wrote: > Note that classes, by default, are based on a contained dict! There are > games to be played with slots that can apparently improve that. I am > not yet experienced enough with Python to know if a slot is as fast as a > C struct, but perhaps it is.
No, slots have nothing to do with speed, they are a memory optimization. IMO slots fall in the category of premature optimization and it was a mistake to include them in the language (the functionality should have been made available only at the C- level). As of now, lots of people abuse slots without realizing their disadvantages (for instance, they break multiple inheritance). -- http://mail.python.org/mailman/listinfo/python-list