On Thu, 30 Aug 2012 05:34:51 -0700 (PDT), Marco Nawijn <naw...@gmail.com> wrote:
If you want attributes to be local to the instance, you have to
define them in the __init__ section of the class like this:

class A(object):
   def __init__(self):
        d = 'my attribute'

Except that in this case you'd need to do:
        self.d = 'my attribute'

Oscar

--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to