Why does this() and super() have to be the first statement in a constructor?

Ulf Zibis Ulf.Zibis at gmx.de
Tue Oct 11 09:57:15 PDT 2011


Am 11.10.2011 18:18, schrieb Per Bothner:
> On 10/11/2011 02:28 AM, Ulf Zibis wrote: In the original example, super(foo) is executed *before*
>> foo.special_init(), so in most cases this workaround would have
>> different result, i.e. is not compatible.
>
> Of course, but it would be pretty rare (and ugly) for super(foo) to
> have the kind of side-effects where the order would matter.
Maybe that was the reason, why it was called "special_init" ;-)

-Ulf




More information about the coin-dev mailing list