Hi,

I just noticed that in the following environment:

class Base:
    def __init__(self):
        ...

class Child(Base):
    pass
    
the following statement:

child = Child()

would automatically execute the superclass __init__ method. This is exactly 
what I was looking for - but in the Cookbook, I found several suggestions on 
how to actively force the invocation of the superclass __init__.

Is this behvaiour documented?

Thanks,

Jan
-- 
There are 10 kinds of people:  those who understand binary, and those who don't
_______________________________________________
Tutor maillist  -  Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor

Reply via email to