Inheritance of constructors.

  • Thread starter Thread starter A n g l e r
  • Start date Start date
Ben said:
In Java, the call to the base constructor doesn't have to be first.

Yes - it does.

It is a method call inside the { }, but it need to be the first
statement, so the difference if purely syntactical.

Arne
 
In C++ it definitely does, I don't see how Borland or Microsoft compiler
would make any difference.

As to Delphi, like it or not, you aren't obliged at all to call any
inherited constructor until you're done with any initialisation bits you
are in need of in first place.

Cheers.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top