When you create a new instance with #new automatically
#initialize is sent.

The default #initialize is provided in ProtoObject at
the highest level of the class hierarchy (doing nothing).

If you look deeper in the hierarchy you will notice that

  - some subclasses of Object override the #initialize
    method and call "super initialize"
  - some subclasses of Object override the #initialize
    method without calling "super initialize"

No problem at the moment as there is no initialization
done in Object or ProtoObject at the current point in
time.

But the question is should we care if there may be
in the future?
I prefer to have a super call for consistency reasons. Igor jokes me usually on that. Now there should not be an initialize in ProtoObject and Object in the future.

So which ones

 - some subclasses of Object override the #initialize
   method without calling "super initialize"



Stef

Thx
T.






Reply via email to