This issue tracker has been migrated to GitHub ,
and is currently read-only.
For more information,
see the GitHub FAQs in the Python's Developer Guide.
Created on 2008年07月09日 07:22 by strangefeatures, last changed 2022年04月11日 14:56 by admin. This issue is now closed.
| Messages (2) | |||
|---|---|---|---|
| msg69460 - (view) | Author: Andy (strangefeatures) | Date: 2008年07月09日 07:22 | |
Suggest clarification on behaviour of the __slots__ attribute when inheriting from classes that don't have __slots__ defined. Obviously the superclass automatically creates __dict__, and it seems the subclass inherits this. I presume this is expected behaviour, but I think it would be worth clarifying in the 'Notes on using __slots__' section - perhaps add something like: "If you define __slots__ on a subclass when its superclass doesn't have __slots__ defined, the superclass will automatically create a __dict__ instance which will be inherited by the subclass (as will other instance attributes). Defining __slots__ on the subclass doesn't block this inheritance." |
|||
| msg70020 - (view) | Author: Georg Brandl (georg.brandl) * (Python committer) | Date: 2008年07月19日 13:09 | |
Added a note in r65136, thanks. |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022年04月11日 14:56:36 | admin | set | github: 47573 |
| 2008年07月19日 13:09:52 | georg.brandl | set | status: open -> closed resolution: fixed messages: + msg70020 |
| 2008年07月09日 07:22:58 | strangefeatures | create | |