Re: Interface inheritance vs Implementation inheritance.
Daniele Futtorovic wrote:
....
With these basic entities, such high-level concepts as callbacks,
closures or concurrent APIs can be built. Entirely transparently so. If
someone wishes to see how it's done, they can, by simply reading the
source code (except for native methods). They can reproduce it freely.
No behind-the-scenes voodoo. Yes, that's it in two words: no voodoo.
I've heard the "no voodoo" argument many times before, initially from
people telling me why assembly languages were better than Fortran or
Algol. Later, procedural languages were better than OO, because you can
see exactly what function will be invoked, no virtual call voodoo.
The increasing semantic gap between what the programmer writes and
what the processor does has been a major theme of programming language
development. The effect has been to greatly increase the effectiveness
of programmers by automating a lot of details.
What's different this time? Does Java really have *exactly* the right
amount of voodoo, so that adding any more will take it past the current
sweet spot?
At least that's what it was like until they introduced the enhanced
for-loop back in Tiger (I'm not entirely sure it was the first
occurrence, but it's just an example, don't quote me on that).
I like the enhanced for-loop. If I just want to do something to every
element in a collection an enhanced for-loop expresses my intent more
directly and clearly than an Iterator idiom.
Patricia