Poo. It looks like the Google groups interface just ate my well-
thought-out and carefully reasoned post. This means that this one is
my grumpy migraine-influenced version...
> Dave Rush wrote:
> >>> JLS3, 12.5
[quoted text clipped - 7 lines]
> But if you want initialiser code to access this (say, an inner class),
> you would be hosed if super had not been called.
Well, potayto, potahto. Gripping hand is that there is no way to run
anything before the superclass constructor code. This is good if you
like flexibility in your reuse patterns, bad if you fear people
reusing your code in surprising ways. So basically the standard
supports incompetent programmers rather than enabling competent ones.
> Don't call overrideable methods from constructors (unless specifically
> designed otherwise).
Well the call of the overridable method wasn't in *my* code. It was in
a 3rd party constructor's and I had no control over that code. This
particular control had gotten good reviews on various java community
sites and has been around for more than a few years, so I expected the
code to be relatively mature. So basically your preaching "never reuse
any black-box code", which is reasonable, but terribly unfashionable
just now.
And do you really want the compiler to barf on any calls of non-final/
non-private methods in a constructor?
david