Michael Foord <[email protected]> added the comment: The list in your example is a *class attribute* not an instance attribute, so yes it is only initialised once. You can still access it through the instance (self) because of Python member lookup rules.
If you want one list per instance then initialise it in __init__ instead of making it a class attribute. In short, Python is not Java. ---------- nosy: +michael.foord resolution: -> invalid status: open -> closed _______________________________________ Python tracker <[email protected]> <http://bugs.python.org/issue7800> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
