On Thu, 09 Oct 2008 01:39:30 -0700, kenneth (a.k.a. Paolo) wrote: > On Oct 9, 10:14 am, Christian Heimes <[EMAIL PROTECTED]> wrote: >> kenneth wrote: >> > the 'd' variable already contains the 'self.d' value of the first >> > instance and not the default argument {}. >> >> > Am I doing some stupid error, or this is a problem ? >> >> No, it always contains the default argument because default values are >> created just ONE >> TIME.http://effbot.org/pyfaq/why-are-default-values-shared-between- objects... > > > Wow, it's a very "dangerous" behavior ...
No, it's very *useful* behaviour. -- Steven -- http://mail.python.org/mailman/listinfo/python-list